lookup> 504

504 ·Gateway Time-out

A gateway or proxy did not receive a timely response from the upstream server.

Server ErrorRFC7231#6.6.5
Status504
PhraseGateway Time-out
TypeServer Error
SpecificationRFC7231#6.6.5

What does HTTP 504 mean?

A gateway or proxy did not receive a timely response from the upstream server.

It belongs to the 5xx Server Error class of responses, defined in RFC7231#6.6.5.

Browse all codes in this class: 5xx Server Error

How to fix HTTP 504

Increase upstream timeouts, optimize slow queries, and check network connectivity.

  • Upstream response timed out
  • Slow database query
  • Network latency between services

Website visitors

Double-check the URL, return to the homepage and search again, or retry later.

Developers

Increase upstream timeouts, optimize slow queries, and check network connectivity.

Server administrators

Check service logs and health, confirm upstream dependencies, restart or scale if needed, then verify monitoring alerts.

Is HTTP 504 cacheable?

504 belongs to the 5xx Server Error class and is generally not cached for long; behavior is controlled by Cache-Control.

What does the 5xx class mean?

5xx Server Error: A gateway or proxy did not receive a timely response from the upstream server.

5xx responses

Related status codes