Unhandled Runtime Error: What It Means and How to Fix It | SheCodes

Uncaught bug · Needs a closer look

Unhandled Runtime Error

An error happened that wasn’t caught. The error message below this line tells you what specifically went wrong.

What the error looks like

Unhandled Runtime Error
TypeError: Cannot read properties of null (reading 'id')

Why it happens

Something in your code threw an error, and nothing caught it. This is a wrapper message: the real clue is in the error details that follow.

How to fix it

  1. Read the more specific error message below “Unhandled Runtime Error”
  2. The line number and file name in the error will point you to the problem
  3. Try pasting the full error (including the details below) into your AI tool for help

Ask your AI coding tool to fix it

Paste this prompt into Claude Code, Cursor, Bolt or Lovable, with your own error in place of the example.

I'm getting this error and I need help understanding and fixing it:

```
Unhandled Runtime Error
TypeError: Cannot read properties of null (reading 'id')
```

Please:
1. Explain what this error means in plain English
2. Tell me the most likely cause
3. Give me the exact code changes or commands I need to fix it
4. Show me how to prevent this error in the future

Got a different error?

Paste any error into the free Error Decoder and get it explained in plain English, with a fix prompt.

Decode my error

More common errors explained