HTTP Status Codes

What every HTTP status code means.

Free tools that run in your browser. Nothing you type, open or create is uploaded to NerdBible or anyone else.

1xx Informational

The request was received and the exchange is still going. Browsers handle these for you and rarely show them.

100 Continue

The server has received the request headers and the client can go ahead and send the body.

Common causes
A client sent Expect: 100-continue before uploading a large body, to check the server would accept it first.
What to do
Nothing. If uploads stall at this point, a proxy in between may not support Expect: 100-continue; disable it in the client.

100 in full: spec, caching, SEO and server examples

101 Switching Protocols

The server agrees to change protocol on this connection, as the client asked in its Upgrade header.

Common causes
Opening a WebSocket, or upgrading a connection to HTTP/2 over plain text.
What to do
Nothing when it works. If WebSockets fail behind a proxy, make sure the proxy passes the Upgrade and Connection headers.

101 in full: spec, caching, SEO and server examples

103 Early Hints

The server sends some headers, usually Link preload hints, before the final response is ready.

Common causes
A server or CDN telling the browser to start fetching CSS, fonts or scripts while the page is still being generated.
What to do
Nothing. It is a speed feature; the final status code follows.

103 in full: spec, caching, SEO and server examples

2xx Success

The request worked.

200 OK

The request succeeded and the response carries the result.

Common causes
A normal page load or API call.
What to do
Nothing. For an API that returns an error message with 200, the server is misreporting the result and the client has to read the body to know.

200 in full: spec, caching, SEO and server examples

206 Partial Content

The server is sending only the part of the file the client asked for in its Range header.

Common causes
Video streaming, resumed downloads and download managers that fetch in pieces.
What to do
Nothing. If a resumed download is corrupt, the file probably changed on the server between requests.

206 in full: spec, caching, SEO and server examples

3xx Redirection

The client has to go somewhere else, or use its cached copy.

301 Moved Permanently

The resource has a new permanent address, given in the Location header.

Common causes
A site moved to HTTPS or a new domain, or a page was renamed.
What to do
Update links and bookmarks. Search engines pass ranking to the new address. Browsers cache 301s hard, so test redirects with 302 first. Browsers may change a POST to GET when following it; use 308 to keep the method.

301 in full: spec, caching, SEO and server examples

304 Not Modified

The cached copy the client already has is still current, so no body is sent.

Common causes
The browser asked with If-None-Match or If-Modified-Since and nothing changed.
What to do
Nothing; this is caching working. If users see stale content, the server is sending the same ETag or date after changes.

304 in full: spec, caching, SEO and server examples

4xx Client error

Something is wrong with the request: the address, the login, the data or the rate.

400 Bad Request

The server could not understand the request.

Common causes
Malformed JSON, a missing required field, an oversized or corrupt cookie, or a bad URL.
What to do
Check the request body and parameters against the API documentation. On a website, clearing the site's cookies often fixes it.

400 in full: spec, caching, SEO and server examples

401 Unauthorized

Authentication is needed and was missing or wrong.

Common causes
No login, an expired session, a missing or invalid API key or token.
What to do
Sign in again or refresh the token. Despite the name it means unauthenticated; for a valid login without permission the code is 403.

401 in full: spec, caching, SEO and server examples

403 Forbidden

The server understood the request but refuses it.

Common causes
Missing permissions, a firewall or bot rule blocking you, a folder without an index page, or file permissions the web server cannot read.
What to do
If it is your site, check file permissions (644 for files, 755 for folders), .htaccess rules and the firewall. As a visitor, try without a VPN, since some sites block their addresses.

403 in full: spec, caching, SEO and server examples

404 Not Found

Nothing exists at this address, or the server will not say that it does.

Common causes
A typo, a deleted or moved page without a redirect, or a broken link.
What to do
Check the address. Site owners should redirect moved pages with 301 and fix internal links.

404 in full: spec, caching, SEO and server examples

421 Misdirected Request

The request reached a server that cannot answer for this domain.

Common causes
HTTP/2 connection reuse across domains that share an address but not a certificate, or a CDN routing problem.
What to do
Retry on a new connection. Site owners should check that the certificate and server names match.

421 in full: spec, caching, SEO and server examples

429 Too Many Requests

The client sent too many requests in a given time and is being rate limited.

Common causes
Scripts or apps calling an API in a tight loop, scrapers, or many users behind one shared address.
What to do
Slow down and retry after the time in the Retry-After header, with exponential backoff in code.

429 in full: spec, caching, SEO and server examples

5xx Server error

The request may be fine but the server failed to handle it.

500 Internal Server Error

Something went wrong on the server and it has no more specific code to give.

Common causes
A bug or crash in the application, a PHP fatal error, a bad .htaccess rule, or a database error.
What to do
Visitors can only retry later. Site owners should check the server and application error logs, which name the actual failure.

500 in full: spec, caching, SEO and server examples

502 Bad Gateway

A proxy, load balancer or CDN got an invalid response from the server behind it.

Common causes
The application server (PHP-FPM, Node, Gunicorn) crashed, restarted or refused the connection.
What to do
Retry in a minute. Site owners should check that the backend service is running and look at the proxy's error log.

502 in full: spec, caching, SEO and server examples

Names follow RFC 9110, the current HTTP standard, and the IANA status code registry. Some services also use unofficial codes that belong to one product and are not part of the standard: nginx's 444 and 499, and Cloudflare's 520, 521, 522, 523, 524, 525 and 526.

How to use it

  1. Type a code such as 503, or a word such as redirect, timeout or cookie.
  2. Read what the code means, what usually causes it and what to do next.
  3. Each code has its own link: click its number to copy a link straight to it.

Questions

What is the difference between 401 and 403?

401 means the server does not know who you are: you are not signed in, or your token is missing or expired. 403 means it knows who you are and you are still not allowed. Signing in again can fix a 401 but not a 403.

Should I use a 301 or a 302 redirect?

Use 301 when a page has moved for good, so search engines move its ranking to the new address. Use 302 for temporary moves. Use 307 or 308 instead when the request is a POST that must stay a POST.

What is the difference between 502, 503 and 504?

All three usually come from a proxy or CDN in front of the site. 502 means the server behind it gave a broken answer or none, 503 means the service is down or overloaded, and 504 means it took too long to answer.

Do status codes affect SEO?

Yes. Search engines index pages that return 200, follow 301 and 308 redirects, drop pages returning 404 or 410 over time, and treat a 503 as temporary. A missing page that returns 200 with an error message (a soft 404) wastes crawling.

About this tool

About this HTTP status code reference

Every response from a web server starts with a three digit status code. Search here by number, such as 503, or by a word such as redirect, timeout or cookie, and each code explains what it means, what usually causes it and what to try next. Click a code's number to copy a direct link to it.

The five classes

  • 1xx: informational, the request is in progress.
  • 2xx: success, such as 200 OK and 204 No Content.
  • 3xx: redirection, such as 301 and 302.
  • 4xx: a problem with the request, such as 404 Not Found.
  • 5xx: a problem on the server, such as 500 and 503.

Pairs people mix up

401 and 403: 401 means the server does not know who you are; 403 means it does and you are still not allowed. Signing in again can fix a 401 but not a 403.

301 and 302: 301 is a permanent move and passes search ranking to the new address; 302 is temporary. 307 and 308 do the same but keep a POST a POST.

502, 503 and 504: usually from a proxy or CDN. 502 is a broken answer from the server behind it, 503 is unavailable or overloaded, 504 is too slow to answer.

Names follow RFC 9110 and the IANA registry. Vendor-specific codes, such as Cloudflare's 52x range, are not listed.

Related tools