Troubleshooting Cloudflare Errors

General | Updated March 2026

When your site uses Cloudflare as a CDN or proxy, error pages may come from Cloudflare rather than your hosting server. Cloudflare errors are numbered in the 5xx and 10xx ranges and each has a different cause. This guide covers the most common Cloudflare errors and how to troubleshoot them with your Ultra Web Hosting account.

01. Cloudflare vs Origin Errors

Cloudflare sits between visitors and your hosting server. When Cloudflare can't reach your server or your server returns an unexpected response, Cloudflare generates its own error page. The key to troubleshooting is figuring out which side has the problem.

Bypass test: Edit your local hosts file (or use curl with --resolve) to point your domain directly to your Ultra Web Hosting server IP, bypassing Cloudflare. If the site works directly, the issue is between Cloudflare and your server. If it doesn't work directly either, the issue is on your server.

02. Error 520: Web Server Returned an Unknown Error

Cloudflare connected to your server but received an empty, malformed, or unexpected response. Common causes:

PHP crash or fatal error - Your script crashed before sending any HTTP headers. Check error_log in your site's directory.

ModSecurity block - ModSecurity dropped the connection. Check Apache error logs for ModSecurity entries.

Response header too large - Cloudflare limits response headers to 32KB. Large cookie headers can trigger this.

Fix: Check your site's error_log and the Apache error log. The 520 is Cloudflare's way of saying "your server said something I didn't understand."

03. Error 521: Web Server Is Down

Cloudflare couldn't connect to your server at all. Your web server (Apache/nginx) is either stopped or refusing connections.

Fix: Verify the web server is running. Check with upordown.ultrawebhosting.com. If the server is down, contact support. Also check that Cloudflare's IP ranges aren't blocked by the server firewall.

04. Error 522: Connection Timed Out

Cloudflare's TCP connection to your server timed out. The server is reachable but didn't respond within 15 seconds. Causes:

Server overloaded - Apache is busy processing other requests and can't accept new connections. Check server load and resource usage.

Firewall blocking Cloudflare IPs - CSF or iptables may be rate-limiting or blocking Cloudflare's IP ranges. Whitelist Cloudflare IPs in the firewall.

Network issues - Routing problems between Cloudflare's data center and your server.

Fix: Check if Cloudflare IPs are whitelisted in CSF (csf.allow). See our Cloudflare setup guide for the correct firewall configuration.

05. Error 523: Origin Is Unreachable

Cloudflare couldn't resolve the DNS for the origin server, or the origin IP address is invalid. This usually means the Cloudflare DNS records are pointing to the wrong IP.

Fix: Log in to your Cloudflare dashboard and verify the A record points to your Ultra Web Hosting server IP. Check the IP in your welcome email or cPanel's left sidebar.

06. Error 524: A Timeout Occurred

Cloudflare connected to your server and the server accepted the request, but it took longer than 100 seconds (on the free/pro plan) to respond. Common for long-running PHP scripts, large file uploads, or database-heavy operations.

Fix: Optimize the slow script. Increase PHP max_execution_time. For operations that genuinely need more time, consider running them via CLI/cron instead of through the web. Cloudflare Enterprise plans allow custom timeout values.

07. Error 525/526: SSL Handshake Failed

Cloudflare couldn't establish an SSL connection with your origin server. This happens when Cloudflare's SSL mode is set to "Full" or "Full (Strict)" but your server doesn't have a valid SSL certificate.

Fix: Ensure your Ultra Web Hosting account has an active SSL certificate (AutoSSL provides one free). In Cloudflare, set SSL mode to "Full (Strict)" if you have a valid certificate, or "Full" if using a self-signed cert. Never use "Flexible" as it creates a redirect loop. See our SSL guide.

08. Error 1000 Series

Error 1000 (DNS points to prohibited IP) - Your Cloudflare DNS is pointing to a Cloudflare IP instead of your origin server IP. Fix the A record.

Error 1001 (DNS resolution error) - Cloudflare can't resolve the hostname. Check that the DNS record exists in Cloudflare.

Error 1006/1007/1008 (Access denied) - Cloudflare blocked the visitor based on your firewall rules, rate limiting rules, or country-based access rules. Check your Cloudflare Security settings.

Error 1015 (Rate limited) - The visitor triggered a Cloudflare rate limiting rule. Review your rate limiting configuration in Cloudflare's Security section.

Error 1016 (Origin DNS error) - CNAME cross-user DNS resolution error. Usually a Cloudflare configuration issue.

Need Help With Cloudflare?

If you're seeing persistent Cloudflare errors, we can check the server side while you check the Cloudflare side. Include the Cloudflare Ray ID from the error page in your ticket.

Open a Support Ticket

Quick Recap: Cloudflare Error Troubleshooting

  1. Test bypassing Cloudflare - Hit your server IP directly to isolate the problem
  2. 520/521/522 - Server-side issues: check Apache, error logs, and firewall
  3. 523 - Wrong origin IP in Cloudflare DNS records
  4. 524 - Script timeout: optimize the slow operation or increase PHP limits
  5. 525/526 - SSL mismatch: ensure your origin has a valid certificate and Cloudflare SSL mode matches

Last updated March 2026 · Browse all General articles

  • 4 Users Found This Useful

Was this answer helpful?

Related Articles

Add Flash Chat to your Website

Obsolete Technology | 2026 This Technology Is No Longer Available Adobe Flash was...

Error 404 - File Not Found

Errors & Troubleshooting | Updated March 2026 A 404 error means the server can't find the...

How to Pass Variables Between HTML Pages

General | Updated March 2026 Plain HTML files cannot pass variables between pages on their...

What perl modules are installed on the server?

Article Updated This article has been consolidated Perl module information is now in our...

How to Create a Support Ticket

General | Updated March 2026 The fastest way to get help with your hosting account is by...



Save 30% on web hosting - Use coupon code Hosting30