HTTP Status Codes
57 status codes explained — what each one means, why you're seeing it, how to fix it, and how to send it from Express, Next.js, Flask, Go or nginx. To see what a live URL returns, use the HTTP Status Checker. For the headers that travel with these responses — Cache-Control, CORS, cookies, security headers — see the HTTP headers reference.
1xx Informational
Interim responses: the request is in progress, the final status is still to come.
100 Continue
The server received the request headers and the client should go ahead and send the body.
101 Switching Protocols
The server agrees to switch the connection to another protocol, most often WebSocket.
103 Early Hints
An interim response that lets the browser start preloading resources while the server is still preparing the page.
2xx Success
The request was received, understood and accepted.
200 OK
The request succeeded, and the response body holds the result.
201 Created
The request created a new resource, usually identified by the Location header.
202 Accepted
The request was accepted for processing, but the work isn't finished yet.
204 No Content
The request succeeded and there is intentionally no response body.
206 Partial Content
The server is returning only the byte range the client asked for.
3xx Redirection
The client must take further action — usually follow the Location header.
300 Multiple Choices
The resource has several representations and the client should pick one.
301 Moved Permanently
The resource has a new permanent URL; clients and search engines should use the Location instead.
302 Found
The resource is temporarily at another URL; keep using the original one for future requests.
303 See Other
Fetch the result from another URL with GET — the standard answer after a form POST.
304 Not Modified
The cached copy is still valid; use it instead of downloading the resource again.
307 Temporary Redirect
A temporary redirect where the client must repeat the exact same request — method and body — at the new URL.
308 Permanent Redirect
The resource moved permanently, and clients must repeat the same method and body at the new URL.
4xx Client Error
The request is wrong in some way; sending it again unchanged won't help.
400 Bad Request
The server can't process the request because something about it is malformed or invalid.
401 Unauthorized
The request lacks valid authentication credentials — the server doesn't know who you are.
402 Payment Required
Reserved for future use; some APIs use it to signal a billing problem.
403 Forbidden
The server understood the request but refuses to allow it.
404 Not Found
The server can't find anything at the requested URL.
405 Method Not Allowed
The URL exists, but it doesn't support the HTTP method used.
406 Not Acceptable
The server can't produce a response matching the request's Accept headers.
407 Proxy Authentication Required
Like 401, but a proxy between you and the server wants credentials.
408 Request Timeout
The server gave up waiting for the client to finish sending the request.
409 Conflict
The request conflicts with the current state of the resource.
410 Gone
The resource was deliberately removed and won't be coming back.
411 Length Required
The server refuses the request because it has no Content-Length header.
412 Precondition Failed
A condition in the request headers, such as If-Match, didn't hold, so nothing was changed.
413 Content Too Large
The request body is bigger than the server is willing to accept.
414 URI Too Long
The URL is longer than the server is willing to process.
415 Unsupported Media Type
The server won't accept the format of the request body (its Content-Type).
416 Range Not Satisfiable
The requested byte range lies outside the resource.
417 Expectation Failed
The server can't meet the requirement in the request's Expect header.
418 I'm a teapot
An April Fools' joke from 1998: the server refuses to brew coffee because it is a teapot.
421 Misdirected Request
The request went to a server that can't produce a response for that hostname.
422 Unprocessable Content
The request is well-formed, but its content fails validation.
423 Locked
The resource is locked and can't be modified right now (WebDAV).
425 Too Early
The server won't process a request that might be replayed, because it arrived as TLS early data.
426 Upgrade Required
The server refuses the request over the current protocol and asks the client to upgrade.
428 Precondition Required
The server requires the request to be conditional, such as with If-Match, to prevent lost updates.
429 Too Many Requests
The client sent too many requests in a given amount of time — it's being rate limited.
431 Request Header Fields Too Large
The request's headers — often its cookies — are too large for the server.
451 Unavailable For Legal Reasons
Access is denied because of a legal demand, such as a court order or a government block.
5xx Server Error
The server failed to fulfil a valid request.
500 Internal Server Error
The server hit an unexpected condition and couldn't complete the request.
501 Not Implemented
The server doesn't support the functionality required — usually an HTTP method it doesn't recognise.
502 Bad Gateway
A proxy or gateway got an invalid response — or none at all — from the upstream server.
503 Service Unavailable
The server is temporarily unable to handle requests — overloaded or down for maintenance.
504 Gateway Timeout
A proxy or gateway didn't get a response from the upstream server in time.
505 HTTP Version Not Supported
The server doesn't support the HTTP version used in the request.
507 Insufficient Storage
The server can't store what's needed to complete the request.
508 Loop Detected
The server found an infinite loop while processing the request (WebDAV).
511 Network Authentication Required
You need to sign in to the network — a captive portal — before you can reach the internet.
Unofficial: nginx & Cloudflare
Not defined by any RFC, but common in logs and on error pages.
499 Client Closed Request
An nginx log code: the client closed the connection before the server sent a response.
520 Web Server Returned an Unknown Error
Cloudflare got an empty, unknown or unexpected response from the origin server.
521 Web Server Is Down
Cloudflare couldn't connect to the origin server because the connection was refused.
522 Connection Timed Out
Cloudflare's TCP connection to the origin server timed out.
524 A Timeout Occurred
Cloudflare connected to the origin, but it didn't send an HTTP response within 100 seconds.