Search This Blog

The Ultimate HTTP Status Codes & Error Resolution Guide

The Complete HTTP Status Codes & Error Resolution Guide
Exhaustive Engineering Reference

The Complete HTTP Status Codes & Error Resolution Guide

An all-inclusive guide detailing every standard IANA status code, RFC extension, WebDAV status, and custom vendor response (Cloudflare, NGINX, AWS, IIS) with actionable fixes.

1xx: Informational Codes

1xx Series
100

Continue

Initial request headers received; client should proceed to send the body payload[cite: 4].

Action
  • Include Expect: 100-continue header before transmitting large POST/PUT requests[cite: 4].
101

Switching Protocols

Server agrees to switch protocols based on the client Upgrade request header[cite: 4].

Action
  • Ensure reverse proxies pass Upgrade and Connection headers for WebSockets[cite: 4].
102

Processing (WebDAV)

Server has accepted the request but has not completed processing (prevents connection timeouts)[cite: 4].

103

Early Hints

Returns preliminary headers before final payload, allowing browsers to start preloading assets[cite: 4].

104

Upload Complete

Draft RFC extension used in resumable uploads to signal that file payload transmission is finished.

2xx: Success Codes

2xx Series
200

OK

Standard success response for completed HTTP requests[cite: 4].

201

Created

Request succeeded and a new resource was created. Includes a Location header[cite: 4].

202

Accepted

Request accepted for processing, but background execution is asynchronous and incomplete[cite: 4].

203

Non-Authoritative Information

Request processed successfully, but returned metadata from a third-party copy.

204

No Content

Successfully processed; intentionally returns an empty response body[cite: 4].

205

Reset Content

Directs the client to reset the active view (e.g., clear form input fields).

206

Partial Content

Delivers part of the resource requested via client Range header (video streaming)[cite: 4].

207

Multi-Status (WebDAV)

Conveys status details for multiple sub-operations inside an XML response payload.

208

Already Reported (WebDAV)

Prevents repeated enumeration of WebDAV bindings inside multi-status responses.

226

IM Used

Server fulfilled GET request; response represents result after applying instance manipulations.

3xx: Redirection Codes

3xx Series
300

Multiple Choices

Multiple resource representations available; client should select one.

301

Moved Permanently

Target resource assigned a new permanent URI[cite: 4]. Update references to retain SEO link equity[cite: 4].

302

Found (Temporary Redirect)

Resource temporarily resides under a different URI[cite: 4].

303

See Other

Directs client to fetch target resource at another URI using a GET request method.

304

Not Modified

Conditional GET resulting in no changes; client can reuse cached copy[cite: 4].

305

Use Proxy (Deprecated)

Legacy code specifying that requested resource must be accessed via proxy.

307

Temporary Redirect (Preserve Method)

Temporary redirect; guarantees request HTTP verb (e.g., POST) remains unchanged[cite: 4].

308

Permanent Redirect (Preserve Method)

Permanent redirect; guarantees request HTTP verb remains unchanged[cite: 4].

4xx: Client Error Codes & Fixes

4xx Series
400

Bad Request

Request cannot be processed due to bad syntax or malformed JSON body[cite: 4].

Client Fix
  • Validate JSON structure and headers prior to dispatch[cite: 4].
401

Unauthorized

Lacks valid authentication credentials for the requested target[cite: 4].

Client Fix
  • Provide a valid Authorization: Bearer <token> header[cite: 4].
402

Payment Required

Reserved for digital payment schemes; used when API quota balance is empty.

403

Forbidden

Authenticated, but lacks authorization permissions to access target resource[cite: 4].

Server Fix
  • Audit user roles/scopes and verify backend access rules[cite: 4].
404

Not Found

Server cannot locate the requested URL path[cite: 4].

Server Fix
  • Configure routing fallbacks or set up 301 redirects[cite: 4].
405

Method Not Allowed

HTTP method not supported by endpoint[cite: 4]. Switch to allowed verb listed in Allow header[cite: 4].

406

Not Acceptable

Resource cannot generate content matching client Accept headers.

407

Proxy Authentication Required

Client must authenticate itself with a proxy server first.

408

Request Timeout

Server timed out waiting for complete client request[cite: 4]. Check upload bandwidth[cite: 4].

409

Conflict

Request conflicts with server state (e.g., duplicate unique entry)[cite: 4].

410

Gone

Target resource permanently deleted with no forwarding address.

411

Length Required

Server refuses request unless Content-Length header is specified.

412

Precondition Failed

Preconditions in request header fields evaluated to false on server.

413

Payload Too Large

Payload body exceeds defined server body limits[cite: 4].

Server Fix
  • Increase maximum body limit (e.g., Nginx: client_max_body_size 50M;)[cite: 4].
414

URI Too Long

Requested URL path / query string is longer than server is willing to interpret.

415

Unsupported Media Type

Payload format unsupported[cite: 4]. Set valid Content-Type header[cite: 4].

416

Range Not Satisfiable

Range specified in Range header field cannot be fulfilled.

417

Expectation Failed

Expectation given in request Expect header field could not be met.

418

I'm a teapot

RFC 2324 April Fools Joke; returned by teapots requested to brew coffee.

421

Misdirected Request

Request directed at server unable to produce a response (e.g., TLS SNI mismatch).

422
Unprocessable Entity (WebDAV)

Syntax correct, but semantic field validation failed.

423

Locked (WebDAV)

Target resource is locked against concurrent edits.

424

Failed Dependency (WebDAV)

Request failed due to failure of a previous dependent request.

425

Too Early

Server unwilling to risk processing request that might be replayed.

426

Upgrade Required

Server refuses request using current protocol; requires client upgrade.

428

Precondition Required

Origin server requires request to be conditional.

429

Too Many Requests

Client exceeded rate limits within time window[cite: 4].

Client Fix
  • Use exponential backoff with jitter; respect Retry-After header[cite: 4].
431

Request Header Fields Too Large

Server unwilling to process request because header fields or cookies are too large.

451

Unavailable For Legal Reasons

Access denied due to official legal demands or government orders.

5xx: Server Error Codes & Fixes

5xx Series
500

Internal Server Error

Generic catch-all error indicating unhandled exceptions or code crashes[cite: 4].

Server Fix
  • Check error trackers (Sentry/Datadog) and handle unhandled promise rejections[cite: 4].
502

Bad Gateway

Reverse proxy received invalid response from upstream application service[cite: 4].

DevOps Fix
  • Ensure backend app process (Node, Gunicorn, PHP-FPM) is active[cite: 4].
503

Service Unavailable

Server down for maintenance or overloaded by traffic spikes[cite: 4].

DevOps Fix
  • Autoscale app instances; serve 503 with a Retry-After header[cite: 4].
504

Gateway Timeout

Reverse proxy timed out waiting for upstream backend response[cite: 4].

Server Fix
  • Optimize database queries; offload tasks to background queues[cite: 4].
505

HTTP Version Not Supported

Server does not support HTTP protocol version used in request[cite: 4].

506

Variant Also Negotiates

Transparent content negotiation configuration error resulting in circular references.

507

Insufficient Storage (WebDAV)

Server unable to store representation needed to complete request.

508

Loop Detected (WebDAV)

Server terminated request because it detected an infinite processing loop.

510

Not Extended

Further extensions to request required for server to fulfill it.

511

Network Authentication Required

Client must authenticate to gain network access (e.g., Wi-Fi captive portals).

Vendor Extensions (NGINX, Cloudflare, AWS, IIS)

Vendor Series
460

Client Closed Connection (AWS ALB)

Client closed the connection before AWS Load Balancer could finish transmitting request.

463

Invalid X-Forwarded-For (AWS ALB)

The X-Forwarded-For header contains more than 30 IP addresses.

444

No Response (NGINX)

NGINX drops connection immediately without returning headers to block malicious traffic/bots.

494

Request Header Too Large (NGINX)

NGINX-specific version of 431 indicating headers exceed memory limits.

495

SSL Certificate Error (NGINX)

An invalid client SSL certificate was presented to NGINX.

496

SSL Certificate Required (NGINX)

Client failed to present a required client-side SSL certificate.

497

HTTP Request Sent to HTTPS Port (NGINX)

An plain-text HTTP request was directed at an HTTPS-encrypted socket.

499

Client Closed Request (NGINX)

Client terminated connection while NGINX was waiting for upstream response.

440

Login Timeout (Microsoft IIS)

Client session has expired and user must log in again.

449

Retry With (Microsoft IIS)

Request cannot be fulfilled because required parameters were omitted.

520

Web Server Returned Unknown Error (Cloudflare)

Origin server returned an empty, unknown, or unexpected response payload.

521

Web Server Is Down (Cloudflare)

Origin server refused connection from Cloudflare edge proxy.

522

Connection Timed Out (Cloudflare)

Cloudflare could not negotiate TCP handshake with origin web server.

523

Origin Is Unreachable (Cloudflare)

Cloudflare could not reach origin server due to routing or DNS failure.

524

A Timeout Occurred (Cloudflare)

Cloudflare connected, but origin server took too long to send HTTP response.

525

SSL Handshake Failed (Cloudflare)

Cloudflare edge network could not negotiate SSL/TLS handshake with origin server.

526

Invalid SSL Certificate (Cloudflare)

Origin server SSL certificate is untrusted, expired, self-signed, or mismatched.

527

Railgun Error (Cloudflare)

Connection failed between Cloudflare's Railgun listener and origin server.

530

Origin DNS Error (Cloudflare)

The requested domain name couldn't be resolved via Cloudflare DNS rules.

No comments:

Post a Comment