Mindfulness

HTTP Code Cheat Sheet: Quick Status Code Meanings

Updated · By the Relaxmid editors

Reading time
5 min
Sections
7
Topic
Mindfulness

HTTP status codes are three-digit numbers a server sends to tell your browser (or any client) what happened with a request. The direct answer: 1xx means informational, 2xx means success, 3xx means redirection, 4xx means client error, and 5xx means server error. For example, when you try to open a page that doesn’t exist, you get a 404 Not Found, which means the server couldn’t find the resource you asked for.

What Do the Number Ranges Mean?

Each hundred-range groups codes by their general outcome. Here’s the quick mental map:

  • 1xx (100–199): Informational. The server is still processing or has received the request. Rarely seen by users.
  • 2xx (200–299): Success. The request worked. The most common is 200 OK.
  • 3xx (300–399): Redirection. The resource moved, and the client should go elsewhere. 301 and 302 are common.
  • 4xx (400–499): Client error. The request was bad, often because of a wrong URL or missing permission.
  • 5xx (500–599): Server error. The server failed to fulfill a valid request.

Memorize the first digit, and you’ll already know the general story. The exact code then tells you the precise reason.

Which Codes Appear Most Often?

Some codes show up constantly in everyday browsing and debugging. Here are the ones worth knowing by heart:

  • 200 OK: The request succeeded. The page or resource loaded normally.
  • 301 Moved Permanently: The resource has a new permanent URL. Browsers and search engines update their records.
  • 302 Found (or Temporary Redirect): The resource is temporarily at a different URL. The original URL stays valid.
  • 400 Bad Request: The server couldn’t understand the request due to malformed syntax or invalid input.
  • 401 Unauthorized: You need to log in or provide credentials. Authentication failed or is missing.
  • 403 Forbidden: You are authenticated but don’t have permission to access the resource.
  • 404 Not Found: The server can’t find the requested resource. The URL is wrong or the resource was deleted.
  • 500 Internal Server Error: The server encountered an unexpected condition. This is a generic server-side failure.
  • 502 Bad Gateway: A proxy or gateway received an invalid response from an upstream server.
  • 503 Service Unavailable: The server is temporarily overloaded or under maintenance. Retry later.

How Do I Use This Cheat Sheet When Debugging?

When you see an error, follow these steps to identify the cause and decide what to do:

  1. Check the first digit. If it’s 4xx, the problem is on your side (or the client’s). If it’s 5xx, the problem is on the server side.
  2. For 4xx errors: Verify the URL spelling, check if you’re logged in (401), and confirm you have permission (403). For 404, the page may have moved—try removing path segments to find a working parent page.
  3. For 5xx errors: Refresh the page after a few seconds. If it persists, check if the server is under maintenance (503) or if there’s a proxy issue (502).
  4. Use browser developer tools (F12 or right-click > Inspect). Go to the Network tab, reload the page, and click on the failed request to see the exact status code and response.
  5. For redirects (3xx): Check if the redirect loop is occurring. A page that redirects to itself will cause a 308 or 301 loop, which the browser stops after several attempts.

If you manage a website, look at server logs for the exact code and the requested URL. That tells you what to fix.

Where Do People Get Confused?

Common misunderstandings trip up both beginners and experienced developers:

  • 401 vs 403: 401 means you haven’t authenticated (no login or wrong password). 403 means you are logged in but not allowed to see the resource. For example, a logged-in user trying to access an admin page gets 403, not 401.
  • 301 vs 302: 301 is permanent; browsers and search engines cache the new URL. 302 is temporary; the old URL should be used next time. Using 302 for a permanent move can hurt SEO.
  • 404 vs 410: 404 means the server doesn’t know if the resource existed. 410 Gone means the resource deliberately removed and won’t return. 410 is more informative but less common.
  • 500 vs 503: 500 is a generic error, often a bug in the code. 503 means the server is temporarily unavailable, like during maintenance. 503 usually includes a Retry-After header.
  • 200 vs 304: 304 Not Modified is used for caching. It tells the browser the cached version is still valid, so it doesn’t download the whole resource again. This is a success, not an error.

What Are Some Less Common Codes I Should Recognize?

Beyond the top ten, these appear in specific situations:

  • 204 No Content: The server processed the request successfully but sends no body. Often used for DELETE requests.
  • 304 Not Modified: Used for caching. The client can reuse its cached copy.
  • 308 Permanent Redirect: Like 301 but preserves the HTTP method (e.g., POST stays POST).
  • 429 Too Many Requests: You sent too many requests in a given time. The server is rate-limiting you. Wait and retry.
  • 451 Unavailable For Legal Reasons: The resource is blocked due to legal demands (e.g., copyright or censorship).
  • 501 Not Implemented: The server doesn’t support the requested method (e.g., a server that only handles GET and POST).
  • 504 Gateway Timeout: A proxy didn’t get a response from the upstream server in time. Often means the server is slow or down.

How Can I Remember the Codes?

Use this rule of thumb: 1xx = hold on, 2xx = here you go, 3xx = go away (to another URL), 4xx = you messed up, 5xx = I messed up. For the exact codes, create a mnemonic: “404 Not Found” is easy because 4 means client error and the page is missing. For 500, think “server has 500 problems.”

When you encounter an unfamiliar code, look it up quickly. The official list is maintained by the Internet Assigned Numbers Authority (IANA) and is available at iana.org. You can also check the MDN Web Docs HTTP status reference for detailed explanations.

What Does 503 Mean for My Website?

If you see 503 on your own site, it often means your hosting server is down or your application is crashing. Check if you’re doing maintenance—if so, that’s expected. Otherwise, contact your hosting provider or check server logs for errors.

Is 404 Always a Bad Sign?

Not necessarily. A 404 can be intentional for deleted pages. But if users land on 404s from internal links, it’s a sign to fix those links or set up redirects to relevant pages.

What Is the Difference Between 301 and 308?

Both are permanent redirects. The difference is that 308 preserves the HTTP method (e.g., POST data is resent), while 301 may change POST to GET in some browsers. Use 308 when you need to redirect form submissions.

Related

General information for everyday wellbeing, not medical advice. If something affects your health, sleep or mood for more than a short while, talk to a qualified professional. Read more

Spotted an error? Tell us and we will correct it (corrections policy).