502
Bad Gateway
5xx Server ErrorWhat It Means
The server received an invalid response from an upstream server while acting as a gateway.
When You'll See It
Common with reverse proxies (Nginx, load balancers) when the upstream application server is down.
Related Status Codes
Frequently Asked Questions
What does HTTP 502 mean?
HTTP 502 Bad Gateway means: The server received an invalid response from an upstream server while acting as a gateway.
When does a server return 502?
Common with reverse proxies (Nginx, load balancers) when the upstream application server is down.
Is 502 a client error or server error?
HTTP 502 is a Server Error (5xx) response. This means the issue is on the server side — the server failed to fulfill a valid request.
Looking for all status codes in one place? Use the interactive HTTP Status Codes reference tool to search and browse all codes.