HTTPError.net

The fastest way to diagnose, understand, and fix any HTTP status code

499 Client Closed Request

Fault: Client (often triggered by a slow server)
Unofficial · nginx
TL;DR

499 is never sent to anyone - the client is already gone. It appears in nginx access logs and usually means the client (or a proxy in front of nginx) gave up waiting.

An nginx-specific code logged when the client closes the connection before nginx sends a response.

Specification note

499 is an unofficial status code used by nginx. It is not part of the HTTP standard or the IANA registry.

What HTTP 499 Client Closed Request Means

An nginx-specific code logged when the client closes the connection before nginx sends a response.

499 is never sent to anyone - the client is already gone. It appears in nginx access logs and usually means the client (or a proxy in front of nginx) gave up waiting.

Common Causes

How to Fix It (For Visitors)

How to Fix It (For Developers/Admins)

Finding the Cause of 499s

Add timing fields to your log format so you can see how long requests took before the client gave up:

log_format timed '$remote_addr "$request" $status '
                 'rt=$request_time urt=$upstream_response_time';
access_log /var/log/nginx/access.log timed;

If 499s cluster around the same duration (for example exactly 30 or 60 seconds), something in front of nginx - a load balancer, CDN, or client library - has a timeout of that length. If they are spread out and the requests are slow, fix the upstream. Occasional 499s from users closing tabs are normal.

The AWS Application Load Balancer equivalent is 460.

Frequently Asked Questions

What does HTTP 499 Client Closed Request mean?

499 is never sent to anyone - the client is already gone. It appears in nginx access logs and usually means the client (or a proxy in front of nginx) gave up waiting. In short: An nginx-specific code logged when the client closes the connection before nginx sends a response.

Is 499 an official HTTP status code?

No. 499 is not registered in the IANA HTTP Status Code Registry; it is specific to nginx. A client that receives an unrecognized status code treats it like the generic 400 code of its class.

How do I fix a 499 Client Closed Request error?

Find slow requests: log $request_time and $upstream_response_time in your access log format. Speed up the slow endpoint or move long work to a background job. Align timeouts so clients and load balancers wait longer than the upstream needs.

Specification Status

499 Client Closed Request is not an official HTTP status code. It is not registered in the IANA HTTP Status Code Registry and is specific to nginx. Other servers and clients may not recognize it.

Source: nginx documentation: proxy_ignore_client_abort →

See all unofficial HTTP status codes →