← All status codes

500

Internal Server Error

It's not you. It's us. Something threw.

When to actually use it

Unhandled exceptions. Log it, then return a generic message — never a stack trace.

Where people mess up

Returning a stack trace and database credentials in the body. That's a gift to attackers, not an error response.

The joke

The server’s “I have no idea what just happened.” It’s the API equivalent of a shrug, immediately followed by the on-call pager.