Http Error: 502 Bad Gateway

Bad gateway

If you receive the 502 bad gateway status code, it means that the server is a gateway or a proxy server that is not receiving a valid response from the backend server(s) that serve the request.

Here are some things to check when encountering this error:

  • The backend servers responsible for handling the requests are healthy.
  • The proxy server is configured correctly.
  • The network connection between the proxy server and backend servers is healthy.
  • Check if the ports between the proxy server and the backend servers are not being blocked by the firewall.

RFC #: 7231 section 6.6.3