HTTP Status Codes
Complete reference of HTTP status codes with meanings and use cases.
Every HTTP status code in the IANA registry, from 100 Continue to 511 Network Authentication Required, with what each one means and when servers send it. Search by number or by word, such as "redirect", "timeout" or "429". Codes are grouped by their first digit: 1xx informational, 2xx success, 3xx redirection, 4xx client errors and 5xx server errors. Common unofficial codes from nginx and Cloudflare, such as 499 and 522, are included and labelled, because you'll meet them in logs even though they aren't in the standard (RFC 9110).
1xx Informational
| 100 | Continue | The server got the request headers; the client should send the body. Used with Expect: 100-continue. |
| 101 | Switching Protocols | The server is switching protocols as requested in the Upgrade header, e.g. to WebSocket. |
| 102 | Processing | WebDAV: the server accepted the request but hasn't finished. Deprecated. |
| 103 | Early Hints | Sends Link headers early so the browser can preload resources while the server prepares the response. |
2xx Success
| 200 | OK | The request succeeded. The body depends on the method: the resource for GET, the result for POST. |
| 201 | Created | A new resource was created. The Location header usually points to it. |
| 202 | Accepted | The request was accepted for processing but hasn't completed, e.g. a queued background job. |
| 203 | Non-Authoritative Information | The response was modified by a proxy from the origin's 200 response. |
| 204 | No Content | Success with no body. Common for DELETE and for PUT/PATCH that don't return the resource. |
| 205 | Reset Content | Success; the client should reset the document view, e.g. clear a form. |
| 206 | Partial Content | Returns part of the resource in answer to a Range request (resumable downloads, video seeking). |
| 207 | Multi-Status | WebDAV: the body holds separate status codes for several sub-requests. |
| 208 | Already Reported | WebDAV: members of a binding already listed earlier in the response. |
| 226 | IM Used | The response is the result of instance manipulations (delta encoding). |
3xx Redirection
| 300 | Multiple Choices | Several representations are available and the client should choose one. Rarely used. |
| 301 | Moved Permanently | The resource has a new permanent URL (in Location). Search engines transfer ranking to the new URL. Clients may change POST to GET. |
| 302 | Found | Temporary redirect to the URL in Location. Clients may change POST to GET; use 307 to keep the method. |
| 303 | See Other | Redirect the client to fetch another URL with GET, typically after a form POST. |
| 304 | Not Modified | The cached copy is still valid (answer to If-None-Match or If-Modified-Since). No body. |
| 305 | Use Proxy | Deprecated for security reasons; don't use. |
| 307 | Temporary Redirect | Temporary redirect that keeps the method and body (a POST stays a POST). |
| 308 | Permanent Redirect | Permanent redirect that keeps the method and body. The method-preserving version of 301. |
4xx Client error
| 400 | Bad Request | The server can't process the request because of a client error: malformed syntax, invalid JSON, bad parameters. |
| 401 | Unauthorized | Authentication is required or failed. Really means “unauthenticated”; the response must include WWW-Authenticate. |
| 402 | Payment Required | Reserved; some APIs use it when a plan's quota or payment has lapsed. |
| 403 | Forbidden | The server understood who you are but refuses access. Logging in again won't help. |
| 404 | Not Found | No resource at this URL. May also hide a resource the client isn't allowed to know about. |
| 405 | Method Not Allowed | The URL exists but doesn't support this method. The Allow header lists the methods it does support. |
| 406 | Not Acceptable | No representation matches the Accept headers the client sent. |
| 407 | Proxy Authentication Required | Like 401, but the proxy between client and server needs credentials. |
| 408 | Request Timeout | The client took too long to send the request; the server closed the connection. |
| 409 | Conflict | The request conflicts with the current state, e.g. an edit conflict or a duplicate unique key. |
| 410 | Gone | The resource was removed permanently and won't come back. Search engines drop it faster than a 404. |
| 411 | Length Required | The server needs a Content-Length header. |
| 412 | Precondition Failed | A conditional header (If-Match, If-Unmodified-Since) didn't match; used for optimistic locking. |
| 413 | Content Too Large | The request body is bigger than the server allows (formerly “Payload Too Large”). |
| 414 | URI Too Long | The URL is longer than the server will handle, often from a GET with a huge query string. |
| 415 | Unsupported Media Type | The server doesn't accept the request body's Content-Type. |
| 416 | Range Not Satisfiable | The requested Range is outside the size of the resource. |
| 417 | Expectation Failed | The server can't meet the Expect header's requirement. |
| 418 | I'm a teapot | An April Fools' joke from the Hyper Text Coffee Pot Control Protocol. Reserved so it isn't reused. |
| 421 | Misdirected Request | The request reached a server that can't produce a response for this host (common with HTTP/2 connection reuse). |
| 422 | Unprocessable Content | The syntax is valid but the content fails validation, e.g. a missing required field. Common in REST APIs. |
| 423 | Locked | WebDAV: the resource is locked. |
| 424 | Failed Dependency | WebDAV: the request failed because a previous request failed. |
| 425 | Too Early | The server won't process a request that might be replayed (TLS 1.3 early data). |
| 426 | Upgrade Required | The client must switch to another protocol, given in the Upgrade header. |
| 428 | Precondition Required | The server requires a conditional request (If-Match) to prevent lost updates. |
| 429 | Too Many Requests | Rate limit exceeded. Retry-After says how long to wait. |
| 431 | Request Header Fields Too Large | Headers are too big, often because of oversized cookies. |
| 444 | No ResponseUnofficial · nginx | nginx closed the connection without sending anything, usually to drop unwanted requests. |
| 451 | Unavailable For Legal Reasons | Access is blocked for legal reasons, such as a court order or government censorship. |
| 499 | Client Closed RequestUnofficial · nginx | nginx logs this when the client disconnected before the server answered. |
5xx Server error
| 500 | Internal Server Error | A generic server-side failure, such as an unhandled exception. Check the server logs. |
| 501 | Not Implemented | The server doesn't support the functionality needed, e.g. an unknown method. |
| 502 | Bad Gateway | A gateway or proxy got an invalid response from the upstream server (it crashed or returned garbage). |
| 503 | Service Unavailable | The server is overloaded or down for maintenance. Retry-After may say when to try again. |
| 504 | Gateway Timeout | A gateway or proxy 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. |
| 506 | Variant Also Negotiates | A content-negotiation configuration error on the server. |
| 507 | Insufficient Storage | WebDAV: the server can't store what's needed to complete the request. |
| 508 | Loop Detected | WebDAV: the server found an infinite loop while processing. |
| 510 | Not Extended | Further extensions to the request are required. Obsolete. |
| 511 | Network Authentication Required | You need to sign in to the network, e.g. a hotel or airport Wi-Fi captive portal. |
| 520 | Web Server Returned an Unknown ErrorUnofficial · Cloudflare | Cloudflare got an empty or unexpected response from the origin server. |
| 521 | Web Server Is DownUnofficial · Cloudflare | Cloudflare couldn't connect to the origin server; it refused the connection. |
| 522 | Connection Timed OutUnofficial · Cloudflare | Cloudflare's connection to the origin server timed out. |
| 523 | Origin Is UnreachableUnofficial · Cloudflare | Cloudflare can't reach the origin, often because of a DNS or routing problem. |
| 524 | A Timeout OccurredUnofficial · Cloudflare | Cloudflare connected to the origin, but it didn't respond within 100 seconds. |
| 525 | SSL Handshake FailedUnofficial · Cloudflare | Cloudflare couldn't complete a TLS handshake with the origin. |
| 526 | Invalid SSL CertificateUnofficial · Cloudflare | Cloudflare couldn't validate the origin server's certificate (Full strict mode). |
Source: IANA HTTP Status Code Registry; RFC 9110 (HTTP Semantics). Unofficial nginx and Cloudflare codes are labelled.
Common use cases
- Work out what an error in a browser, log or API response means
- Pick the right status code when building an API
- Debug redirects, caching and authentication
- Explain an outage or error page to someone non-technical
How to use
- Type a code or a keyword in the search box.
- Read the meaning and when it's used.
- Check the label for codes that are unofficial or specific to one server.
FAQ
What's the difference between 401 and 403?
401 Unauthorized means you aren't logged in, or your credentials are missing or invalid, so try again with them. 403 Forbidden means the server knows who you are but won't let you in, and logging in again won't help.
Should I use 301 or 302 for a redirect?
301 for a permanent move, so search engines move ranking to the new address; 302 for a temporary one. 308 and 307 are the same pair but guarantee the request method (such as POST) isn't changed.
What do 502, 503 and 504 mean?
All three point to a server problem rather than yours. 502 Bad Gateway: a proxy got a bad reply from the server behind it. 503 Service Unavailable: the server is overloaded or down for maintenance. 504 Gateway Timeout: the server behind the proxy took too long to answer.
What does 429 Too Many Requests mean?
You've hit a rate limit. Slow down and try again later; the response often has a Retry-After header saying how long to wait.
Related tools
- SMTP Status CodesEmail server response codes and their meanings for troubleshooting.
- DNS Record TypesReference for DNS record types including A, AAAA, CNAME, MX, TXT, and more.
- Port Number LookupCommon network port numbers and their associated services.
- File Extension LookupFile extension database with associated programs and MIME types.
- MIME Type LookupMIME type reference for content type headers and file handling.
- URL ParserIn Utilities
- cURL Command GeneratorIn Utilities
- HTTP Request BuilderIn Utilities