The error, verbatim
Jump to the fix ↓Error 1101
Worker threw exception
# the same request from curl:
HTTP 500
error code: 1101
# npx wrangler tail --format pretty, same request:
GET https://nk-repro-cpu.nilaykabariya12.workers.dev/binding - Exception Thrown
X [ERROR] TypeError: Cannot read properties of undefined (reading 'get')
at handle (index.js:54:31)
The fix that worked
See the real error, then fix that line:
npx wrangler tail --format prettyNot it? Every cause, tested ↓Tested on
- wrangler
- 4.139.0; 4.158.0 (November 8)
- Worker
- compatibility_date 2026-09-01, nodejs_compat
- OS
- Windows 11 Pro
Contents
Error 1101 means your Worker’s code threw an error while handling the request, so Cloudflare answered with its own error page instead. That page never says what went wrong. The real error is in your Worker’s logs.
The fix
1. See the real error. In your project folder, stream the live logs, then reload the page that shows 1101:
npx wrangler tail --format prettyEach failed request prints the actual exception and where it happened:
GET https://nk-repro-cpu.nilaykabariya12.workers.dev/binding - Exception Thrown
X [ERROR] TypeError: Cannot read properties of undefined (reading 'get')
at handle (index.js:54:31)2. Make the line number point at your code. index.js:54 is a line in the bundle wrangler uploaded, not in your file. Add this to your wrangler config and deploy again:
// wrangler.jsonc
"upload_source_maps": true3. Find the message in the table below and fix that line.
Six causes, each reproduced
Each of these returned Error 1101, and each one logs a different message:
| Your code | What wrangler tail shows |
Fix |
|---|---|---|
Reads a property of something that’s undefined |
TypeError: Cannot read properties of undefined (reading 'email') |
Check the value exists before using it |
| Uses a binding (KV, D1, R2…) that isn’t in the config you deployed | TypeError: Cannot read properties of undefined (reading 'get') |
Declare the binding in the wrangler config you deploy with |
Returns a string or object instead of a Response |
TypeError: Incorrect type for Promise: the Promise did not resolve to 'Response'. |
Return new Response(...) or Response.json(...) |
Calls fetch('/api/data') with a relative URL |
TypeError: Invalid URL: /api/data |
Give fetch a full URL, starting with https:// |
Calls request.json() on a request with no body |
SyntaxError: Unexpected end of JSON input |
Only parse JSON on requests that send it, and answer 400 when it’s invalid |
| Waits on a promise that never settles | Error: The Workers runtime canceled this request because it detected that your Worker's code had hung and would never generate a response. |
Find the await that never finishes |
If the message is D1_ERROR: D1 query result exceeded the maximum response size limit of 50 MB, the code is fine but the query now returns more than D1 allows: the D1 50 MB limit, tested.
I re-ran all six on November 8, 2026 with wrangler 4.158.0: every route still returned HTTP 500 with error code: 1101, and wrangler tail logged the same six messages, word for word:

Stop visitors seeing the 1101 page
An error you don’t catch becomes Cloudflare’s page. Catch it yourself, log it, and send your own response:
export default {
async fetch(request, env) {
try {
return await handle(request, env);
} catch (err) {
console.error(err);
return new Response('Something went wrong', { status: 500 });
}
},
};
One side effect to know about: wrangler tail now marks those requests Ok, because the Worker did return a response. Search the log lines, not the status.
If you’re a visitor, not the site owner
The page means that site’s own code crashed on your request. It’s almost never something on your side, and only the site’s owner can fix it. Reloading won’t help: in my tests the same request failed again on every retry, five times in a row for one of them.
What didn’t work
The test Worker
One test Worker deployed with wrangler 4.139.0 to workers.dev, with a route for each cause in the table, plus the same routes wrapped in try/catch. Each route was requested with curl (and one in a browser, for the page text), and every message above is copied from wrangler tail --format pretty for that request. Source maps were checked by redeploying with "upload_source_maps": true and triggering the same errors.
November 8, 2026: the six causes again with wrangler 4.158.0 and compatibility_date 2026-11-01, one route each, logged with wrangler tail --format json. The Worker, config, curl results and tail log are public.
— N.K., end of entry No.025