What 522 means
Cloudflare tried to open a TCP connection to the origin and got no answer: the server is overloaded, unreachable or dropping Cloudflare's packets.
Common causes
- An overloaded or offline origin.
- A firewall silently dropping Cloudflare's IPs.
- Wrong origin IP in the DNS settings.
How to fix it
If you're calling an API
- Retry later; the problem is on the site's side.
If you run the server
- Check server load, firewall rules (allow Cloudflare IPs) and that DNS points at the right origin IP.
Should you retry?
Yes, with backoff.
Example response
HTTP/1.1 522 Connection Timed Out
Content-Type: application/problem+json
{
"type": "about:blank",
"title": "Connection Timed Out",
"status": 522,
"detail": "Cloudflare's connection to the origin server timed out."
}Defined in: Cloudflare (non-standard). 522 is a server error: the problem is on the server's side.
Debugging an API call? Convert your request with the cURL converter, check the response with the JSON formatter, or see whether the API is down on its status page.