HTTP Status Code Reference — Complete Guide for Developers and SEOs
Every HTTP response comes with a three-digit status code that tells the client — and search engine crawlers like Googlebot — exactly what happened with the request. Whether you are debugging a 502 bad gateway error, deciding whether to use 301 or 302, or designing a REST API response, this reference gives you the meaning, use cases, and practical notes for every code.
Search by code number or keyword, or filter by class using the buttons above.
HTTP Status Code Classes — What the First Digit Means
The first digit of every status code defines its class. Understanding the five classes is the fastest way to triage any HTTP error:
| Class | Range | Meaning | SEO Impact |
|---|---|---|---|
| 1xx | 100–199 | Informational — request received, processing continues | Minimal — rarely seen by crawlers |
| 2xx | 200–299 | Success — request completed successfully | Critical: 200 required for indexing |
| 3xx | 300–399 | Redirection — further action needed | High: 301 passes link equity; 302 does not consolidate |
| 4xx | 400–499 | Client error — bad request or not found | High: 404/410 remove pages from the index |
| 5xx | 500–599 | Server error — server failed the request | High: persistent 5xx triggers crawl reduction and de-indexing |
Most Important HTTP Status Codes Explained
2xx — Success Codes
200 OK is the baseline. The request succeeded and the server returned the requested resource. This is the only status code that makes a page eligible for Google indexing. Watch for "soft 404s" — pages that return 200 but display empty or error-like content, which Google treats as missing pages that waste crawl budget.
201 Created is the correct response after a successful POST request that created a new resource in a REST API. Not seen by web crawlers on public HTML pages.
204 No Content signals success with no body to return. Use it in DELETE and PATCH API endpoints when you do not need to return updated data.
3xx — Redirect Codes
301 Moved Permanently is the permanent redirect. It consolidates ranking signals — including link equity and PageRank — from the old URL to the new one. Use it for URL restructures, domain changes, HTTP-to-HTTPS migrations, and any scenario where the old URL will never return. 301 redirects are cached aggressively by browsers — test carefully before deploying at scale.
302 Found is the temporary redirect. Google passes ranking signals through 302s in its current implementation, but leaving a 302 in place long-term prevents Google from updating its index and creates canonical ambiguity. Use 302 for A/B tests, geo-based redirects, and seasonal promotion pages.
304 Not Modified tells the browser to serve its cached version. The resource has not changed since the last request. This reduces bandwidth and speeds up repeat visits with no negative SEO impact.
4xx — Client Error Codes
401 Unauthorized means authentication is required and has not been provided or is invalid. The user needs to log in or provide an API key. Not the same as 403 — 401 means "Who are you?" while 403 means "I know who you are, and you cannot come in."
403 Forbidden means the server understood the request but refuses to authorize it. The client's identity is known but lacks permission. From an SEO perspective, Googlebot receiving a 403 on a previously indexed page may eventually cause that page to drop from search results.
404 Not Found is the most common error on the web. A moderate number of 404s is normal — they only become a problem when important pages return 404 without being redirected, wasting link equity. Redirect high-value 404s with a 301 to the most relevant alternative.
410 Gone is the permanent removal signal. Stronger and faster than 404 — Google processes 410 for URL removal much more quickly than 404. Use it when you intentionally retire content that will never return.
429 Too Many Requests signals rate limiting. If Googlebot receives 429 responses, it slows its crawl rate, reducing your crawl budget. Implement rate limiting carefully and ensure crawlers are not aggressively throttled.
5xx — Server Error Codes
500 Internal Server Error is a generic server failure. Monitor for 500s in Google Search Console — persistent 500s on a URL cause Google to lower crawl frequency and may trigger de-indexing.
502 Bad Gateway means the server received an invalid response from an upstream server. Common with Nginx or Cloudflare when the application server is down, crashed, or overloaded after a failed deployment.
503 Service Unavailable means the server is temporarily unavailable. Always include a Retry-After header so Google knows when to re-crawl. Without it, persistent 503s can trigger de-indexing. This is the correct code to return during planned maintenance.
504 Gateway Timeout means the gateway did not receive a timely response from the upstream server. Common root cause: a slow database query, a hanging API call, or a background job that exceeds the request timeout.
301 vs 302 — When to Use Each
| Scenario | Use | Reason |
|---|---|---|
| Page moved permanently | 301 | Passes full link equity to new URL |
| HTTPS migration | 301 | Permanent — consolidates ranking signals |
| Domain change | 301 | Permanent — preserves rankings |
| A/B test | 302 | Temporary — keeps original URL canonical |
| Seasonal promotion | 302 | Temporary — original URL returns after promo |
| Geo-based redirect | 302 | Temporary — varies by user location |
| Maintenance page | 503 + Retry-After | Not a redirect — server temporarily down |
Frequently Asked Questions
What is the difference between a 404 and a 410 HTTP status code?
Both 404 Not Found and 410 Gone tell the browser and search engine crawlers that a page is unavailable. The key difference is permanence and intent. A 404 means the server cannot find the resource — it may exist again in the future. A 410 explicitly declares the resource is permanently removed and will not return. From an SEO perspective, Google processes 410 faster than 404 for URL removal — use 410 when you intentionally retire content and want it removed from Google's index as quickly as possible.
What is the difference between 401 Unauthorized and 403 Forbidden?
Both codes indicate access is denied, but for different reasons. 401 Unauthorized means the client has not authenticated — the server does not know who you are and you need to provide credentials (log in or supply an API key). 403 Forbidden means the server knows who you are but refuses access — you are authenticated but lack permission to view that resource. Think of it as: 401 = "Who are you?", 403 = "I know who you are, but you cannot come in."
Does a 301 redirect pass SEO value (link equity) to the new URL?
Yes. A 301 Moved Permanently redirect consolidates ranking signals — including link equity, PageRank, and indexing authority — from the old URL to the new one. Google has confirmed that 301 redirects pass full link equity, though redirect chains (multiple hops) may cause a small amount of signal loss. A 302 Found also passes signals in Google's current implementation, but 301 is always the safer choice for permanent moves.
How do HTTP status codes affect Google crawling and indexing?
Status codes directly determine how Googlebot treats each URL. A 200 OK makes a page eligible for indexing. A 301 tells Google to update its index to the new URL and transfer link equity. A 404 or 410 tells Google the page is gone — it will eventually be removed from the index. A 503 with a Retry-After header tells Google to try again later without de-indexing. Persistent 5xx errors cause Google to reduce crawl frequency and eventually de-index affected pages. A 429 response throttles Googlebot, reducing how many pages it can crawl per day.
What is a "soft 404" and why is it an SEO problem?
A soft 404 occurs when a page returns 200 OK but displays content that looks like an error page — an empty result, "no products found," or a generic "page not available" message. Google detects these visually and treats them like real 404s, classifying the URL as missing content. This wastes crawl budget and prevents the page from being indexed or ranked. The fix is to either return a genuine 404 or 410 status code, or populate the page with real, meaningful content.
Resources
- MDN Web Docs — HTTP response status codes — The authoritative reference for all HTTP status codes with detailed specifications.
- RFC 9110 — HTTP Semantics — The official IETF standard defining HTTP status code semantics and behavior.
- Google Search Central — HTTP status codes — How Googlebot interprets specific status codes and their impact on crawling and indexing.