Guide

HTTP status codes: the ones that matter and how to fix them

Reviewed 22 November 2026 · 7 min read · Written and maintained by Toolnexo

Every response a web server sends starts with a three-digit status code. Most of the time you never see it, but when something breaks it is the quickest clue to who needs to fix what. This guide groups the codes that come up in real work, explains the pairs people confuse, and notes what each means for search engines. The full list, with search and fix tips, is in the HTTP status codes reference on this site, which runs in your browser.

How to read a code

The first digit gives the class. 1xx is informational, 2xx means the request succeeded, 3xx means the client should look elsewhere, 4xx means the request has a problem, and 5xx means the server failed to handle a valid request. That first digit already tells you where to look: a 4xx points at the request or the address, a 5xx at the server or something behind it.

Success codes

  • 200 OK: the request worked and the response has the content.
  • 201 Created: a new resource was made, common after a POST that adds a record.
  • 204 No Content: it worked and there is nothing to send back, common after a delete.
  • 304 Not Modified: the cached copy is still current, so the server sent no body. This saves bandwidth and is a good sign.

Redirects: 301, 302, 307 and 308

301 means moved permanently, 302 means found at another address for now. For SEO, a permanent redirect tells search engines to treat the new address as the main one and carry the old page's signals across, while a temporary one tells them to keep the original. Use 301 when you change a URL for good and 302 for short-lived moves such as a seasonal page.

307 and 308 are the strict versions of 302 and 301: they guarantee that the request method, such as POST, is repeated unchanged at the new address, which older browsers did not always do with 301 and 302. For ordinary page redirects, 301 and 308 are treated as permanent and 302 and 307 as temporary. Avoid long redirect chains: each hop adds delay and can waste crawl effort.

Client errors: 400, 401, 403, 404, 410 and 429

401 Unauthorized means you must authenticate: credentials are missing or wrong, and signing in may fix it. 403 Forbidden means the server knows who you are and still refuses, so signing in again will not help; check permissions, IP rules or a firewall. 400 Bad Request means the request itself is malformed, such as invalid JSON or a bad parameter.

404 Not Found means nothing exists at that address. 410 Gone says the same thing but states that it was removed on purpose and is not coming back. Search engines treat both as removed pages. Fix a 404 by restoring the page, redirecting it to the closest replacement, or correcting the link. Watch for soft 404s, where a missing page returns 200 with a not-found message, which Google reports as a problem.

429 Too Many Requests means you are being rate limited. Wait before retrying, look for a Retry-After header, and slow down or cache on the client side.

Server errors: 500, 502, 503 and 504

500 Internal Server Error is the catch-all for an unhandled failure in the application; the cause is in the server logs. 502 Bad Gateway means a proxy or gateway such as nginx or a CDN received an invalid response from the server behind it, often because the application crashed or restarted. 504 Gateway Timeout means the gateway got no response in time, so look for slow queries, overloaded workers or timeouts set too low.

503 Service Unavailable means the server is temporarily unable to handle requests, for example during maintenance or overload. It is the right code for planned downtime, ideally with a Retry-After header, because search engines treat it as temporary and come back. Long runs of 5xx or 429 responses make crawlers slow down, so fix them promptly.

Codes you will see behind a CDN

Some codes are not in the HTTP standard. nginx logs 499 when the client closed the connection before the server answered. Cloudflare uses 520 for an unknown error from the origin, 521 when the origin refused the connection, 522 and 524 for connection and response timeouts, 523 when the origin is unreachable, and 525 and 526 for SSL problems between Cloudflare and your server. In every case the page you see comes from the CDN, but the fault is usually at your own origin.

A quick debugging routine

  • Note the first digit: is the problem in the request or on the server?
  • Open the browser's network tab or run curl -I on the URL to see the real status code and headers.
  • For 5xx errors, check the application and proxy logs at the time of the request.
  • For 3xx, follow each hop and make sure the chain is short and ends in a 200.
  • For 4xx on a page you want indexed, restore it or redirect it, then confirm the final status is 200.
Tools in this guide

Put it into practice

How this guide is maintained

This page is reviewed when the related tools change. It describes what the published tools actually do: the tools run in your browser tab, so your files stay on your device. If you find something inaccurate, email [email protected] and it will be corrected.

Keep reading

Other guides

All guides →