← Back to Toolbox

HTTP Status Codes

Updated October 2026 · Run into a weird status code while debugging an API? Check the table first

The first digit tells you the category: 1xx informational, 2xx success, 3xx redirection, 4xx the client's fault, 5xx the server's fault. When debugging, look at the group first, then the specific code.

1xx Informational

Status codeNameDescription
100ContinueThe request headers have been received and the client may go ahead and send the body. Shows up on large uploads with Expect: 100-continue.
101Switching ProtocolsThe protocol switch succeeded — most commonly an HTTP upgrade to WebSocket.
103Early HintsThe main response isn't ready yet, but the server tells the browser which CSS/JS to preload, speeding up first paint.

2xx Success

Status codeNameDescription
200OKThe request succeeded — the most common status code. Note: 200 only means success at the HTTP layer; check the body's code field for business-level errors.
201CreatedA new resource was created — the standard response for POST endpoints that create something.
202AcceptedAccepted but not yet processed — common for async jobs (exports, transcoding).
204No ContentSucceeded with no response body — common for DELETE endpoints. Returning 204 with a body is non-standard.
206Partial ContentA range request succeeded — resumable downloads and video seek bars rely on it.

3xx Redirection

Status codeNameDescription
301Moved PermanentlyPermanent redirect — browsers cache it and search engines transfer ranking. Use it for domain changes and HTTP→HTTPS.
302FoundTemporary redirect. Watch out: most browsers rewrite the redirected POST into a GET.
304Not ModifiedThe cache is still fresh, so the server sent no body. When an API "doesn't update" while debugging, suspect this first — clear the cache or hard-refresh to verify.
307Temporary RedirectTemporary redirect that does not change the request method or body — a POST stays a POST.
308Permanent RedirectPermanent redirect that likewise preserves the method — the strict version of 301.

4xx Client Errors

Status codeNameDescription
400Bad RequestThe request itself is broken: missing parameters, malformed JSON, etc. First reaction: check the parameters you sent.
401UnauthorizedNot authenticated: not logged in, token missing or expired. Despite the name, it really means "identity not yet verified".
403ForbiddenAuthenticated but not allowed. The difference from 401: 401 asks "who are you?", 403 says "we know who you are — and no".
404Not FoundThe resource doesn't exist: wrong path, nonexistent id, or an unregistered route. Check the URL spelling and environment domain first.
405Method Not AllowedThe path is right but the method is wrong — e.g. POSTing to a read-only endpoint.
408Request TimeoutThe client sent the request too slowly and the server timed out waiting. Common on large uploads over weak networks.
409ConflictState conflict: creating a unique resource twice, or a version clash (optimistic-lock failure).
410GoneThe resource existed and has been permanently deleted — more explicit than 404, and used a lot in SEO.
413Payload Too LargeThe request body is too big. For uploads, check Nginx's client_max_body_size and gateway limits first.
422Unprocessable EntityWell-formed but semantically wrong — form validation failures often use it to return field-level errors.
429Too Many RequestsYou're being rate-limited. Check the Retry-After response header and retry with backoff — don't hammer the endpoint.

5xx Server Errors

Status codeNameDescription
500Internal Server ErrorThe server code threw an exception. Front end: stop guessing and go read the server-side log stack trace.
501Not ImplementedThe feature isn't implemented — e.g. you used a method the server doesn't support.
502Bad GatewayThe gateway/reverse proxy got no sane response from upstream: the upstream is down, the port is wrong, or the process crashed. Check whether the backend process is alive first.
503Service UnavailableTemporarily unavailable: restarting, shedding load, or under maintenance. Usually transient — retry in a bit.
504Gateway TimeoutThe gateway waited too long for upstream: it's up, just slow. Versus 502: 502 means "answered wrong / not at all", 504 means "took too long".

Debugging Rules of Thumb

For 4xx, check yourself first: parameters, token, URL, method — it's the front end or the caller nine times out of ten.
For 5xx, check the chain: 502 → the upstream process, 504 → slow endpoints / slow SQL, 500 → the application logs.
If an API is "flaky", think 429 (rate limiting) and 503 (instances being drained / a deploy in progress) first.

Keep looking things up

Git Cheat Sheet →   Regex Cheat Sheet →