522 Connection Timed Out β
Meaning β
A Cloudflare-specific status indicating that the proxy did not receive a timely response from the origin server. It is essentially a timeout between Cloudflare and the origin.
When to Use β
When Cloudflare can connect to the origin server but the server takes too long to respond to the request. This is similar to a 504 but specifically in the context of Cloudflare communicating with the origin.
Example β
If the origin server is overwhelmed or slow and doesn't respond to Cloudflare's request within Cloudflareβs timeout window, Cloudflare returns a 522 Connection Timed Out to the client to signal the upstream timeout.
When Not to Use β
Do not use directly on origin servers. This is meant for proxies/gateways. If you are implementing a proxy or load balancer and want a similar concept, you might use 504 Gateway Timeout. 522 is part of Cloudflareβs nomenclature for timeouts.
Source β
Unofficial (Cloudflare)