Contents
To fetch a page, Cloudflare first opens a TCP connection to your server and then sends the request. With a 522 one of those steps stalled: either the server never answered the connection attempt, or it accepted and then went quiet. The key difference from a 521 is that the server didn’t refuse; it stayed silent until the timeout. Silence usually means overload, a block that drops packets without replying, or an address with nothing behind it.
What causes error 522
- Load on the server or account: the site is at its resource limits, so new connections queue until the timeout expires. See server load.
- A firewall silently dropping Cloudflare’s connections: a block that ignores packets rather than refusing them, so Cloudflare keeps waiting.
- A wrong IP in the A record: an old server’s address after a migration, or one that doesn’t respond at all.
- A network or routing problem between Cloudflare and the server’s network.
- Keep-alive connections closed by the server in a way Cloudflare doesn’t expect.
Fixing it as a visitor
Try again in a few minutes. It isn’t your device or your connection.
Fixing it as the site owner
- Confirm the address: compare the IP in cPanel’s General Information panel with the A records in Cloudflare under DNS → Records. You can also check them with the DNS lookup tool.
- Test the server directly with a short timeout:
curl -sv --connect-timeout 10 --resolve example.com:443:203.0.113.10 https://example.com/ -o /dev/null
Replace 203.0.113.10 with your server’s address. If it times out here too, the problem is the server or network. If it answers quickly, the problem is specific to the path between Cloudflare and the server.
3. Check resource usage: open Metrics → Resource Usage in cPanel and see whether limits were hit when the error appeared. If so, reduce load with caching, blocking abusive bots, and disabling heavy plugins.
4. Cache at both Cloudflare and the site: let Cloudflare serve static files from its cache and enable LiteSpeed Cache in WordPress, so fewer requests reach the server.
5. If the server answers your direct test but fails only from Cloudflare, the server firewall may be dropping Cloudflare’s connections. Contact support with the time and Ray ID so they can review the block.
6. If the error comes and goes at certain times, compare those times with the Metrics → Raw Access log to see whether they match cron jobs, campaigns or crawlers.
If your browser shows ERR_CONNECTION_TIMED_OUT without a Cloudflare page, see that error.
Prevention
- Keep an eye on Resource Usage and deal with repeated faults before they turn into outages.
- Make your site’s security tools read the real visitor IP from the
CF-Connecting-IPheader. - When you change hosts, update DNS records in Cloudflare the same day.
On ArabyHost
Every account has its own CloudLinux LVE resource limits, and the Resource Usage page shows any faults against them. Sites run on LiteSpeed, with the LiteSpeed Cache plugin for WordPress to take load off, and Imunify360 protects the server. If an Imunify360 block is dropping Cloudflare’s connections, support can review it. See using Cloudflare with your hosting.
FAQ
What's the difference between 522 and 524?
With 522 the connection to the server never completed, or the server didn't respond to the request after accepting it. With 524 the connection worked and the request arrived, but the server took too long to send the full response.
Why do I only see 522 at peak times?
The server or account is hitting its resource limits, so new connections wait until Cloudflare's timeout runs out. Caching and cutting heavy requests usually fix it.
Could the problem be Cloudflare's network?
Rarely, when there's a routing issue between Cloudflare and the server's network. If the server answers quickly when tested directly from different places, send the Ray ID and time to support so the network can be checked.