{"id":8574,"date":"2026-05-28T09:55:31","date_gmt":"2026-05-28T07:55:31","guid":{"rendered":"https:\/\/mybox.com\/help\/?post_type=manual_kb&#038;p=8574"},"modified":"2026-06-15T01:39:24","modified_gmt":"2026-06-14T23:39:24","slug":"cum-sa-remediati-eroarea-520-web-server-is-returning-an-unknown-error-in-cloudflare","status":"publish","type":"manual_kb","link":"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/","title":{"rendered":"Cum s\u0103 remedia\u021bi eroarea 520 (\u201cWeb Server Is Returning an Unknown Error\u201d) \u00een Cloudflare"},"content":{"rendered":"<div class=\"translation-block translation-block-merged\">\n<p class=\"wp-block-paragraph\">Error 520 is one of the most common Cloudflare errors. It occurs when Cloudflare successfully connects to your origin server, but the server returns an unexpected, empty, or invalid response.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Unlike errors such as 521 or 522, Error 520 usually indicates that the web server is responding, but something is preventing Cloudflare from processing the response correctly.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_86 ez-toc-wrap-left counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#What_Causes_Error_520\" >What Causes Error 520?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Check_Your_Website_Without_Cloudflare\" >Check Your Website Without Cloudflare<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Review_Server_Error_Logs\" >Review Server Error Logs<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Check_Firewall_Configuration\" >Check Firewall Configuration<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Verify_SSL_Configuration\" >Verify SSL Configuration<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Disable_Problematic_Plugins\" >Disable Problematic Plugins<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Check_Server_Resources\" >Check Server Resources<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Verify_the_htaccess_File\" >Verify the .htaccess File<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Clear_Cloudflare_Cache\" >Clear Cloudflare Cache<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Contact_Your_Hosting_Provider\" >Contact Your Hosting Provider<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/mybox.com\/help\/ro\/knowledgebase\/how-to-fix-error-520-web-server-is-returning-an-unknown-error-in-cloudflare\/#Summary\" >Summary<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"What_Causes_Error_520\"><\/span>What Causes Error 520?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<\/div>\n\n<div id=\"mybox-2172964751\" class=\"mybox-content mybox-entity-placement\"><div class=\"early-access-banner-inpost\">\r\n  <div class=\"banner-left-inpost\">\r\n    <div class=\"icon-box-inpost\">\r\n      <img decoding=\"async\" src=\"https:\/\/mybox.com\/help\/wp-content\/uploads\/2026\/02\/square-info-icon.svg\" alt=\"Info\">\r\n    <\/div>\r\n    <div class=\"text-box-inpost\">\r\n      <span class=\"label-inpost\"><span class=\"translation-block translation-block-banner-text\">Acces timpuriu<\/span><\/span>\r\n      <h4><span class=\"translation-block translation-block-banner-text\">Mai ave\u021bi nevoie de ajutor?<\/span><\/h4>\r\n      <p><span class=\"translation-block translation-block-banner-text\">Contacta\u021bi echipa noastr\u0103 de servicii pentru clien\u021bi.<\/span><\/p>\r\n    <\/div>\r\n  <\/div>\r\n\r\n  <div class=\"banner-right-inpost\">\r\n    <a href=\"https:\/\/panel.mybox.com\/helpdesk2\/v\/list\/\" class=\"banner-button-inpost\"><span class=\"translation-block translation-block-banner-text\">Trimite mesaj<\/span><\/a>\r\n  <\/div>\r\n<\/div><\/div>\n\n<div class=\"translation-block translation-block-merged\"><p class=\"wp-block-paragraph\">Several issues can trigger Error 520, including:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>PHP application errors<\/li>\n\n\n\n<li>Server resource exhaustion<\/li>\n\n\n\n<li>Firewall rules blocking Cloudflare IP addresses<\/li>\n\n\n\n<li>Corrupted <code>.htaccess<\/code> files<\/li>\n\n\n\n<li>Invalid HTTP headers<\/li>\n\n\n\n<li>Large response headers or cookies<\/li>\n\n\n\n<li>Misconfigured SSL settings<\/li>\n\n\n\n<li>WordPress plugins or themes generating fatal errors<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Check_Your_Website_Without_Cloudflare\"><\/span>Check Your Website Without Cloudflare<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The first step is to determine whether the problem originates from Cloudflare or your website.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Temporarily pause Cloudflare or switch the affected DNS record from <strong>Proxied<\/strong> (orange cloud) to <strong>DNS Only<\/strong> (grey cloud).<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If the website still displays errors, the problem is likely on the origin server.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If the website works correctly without Cloudflare, continue with the steps below.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Review_Server_Error_Logs\"><\/span>Review Server Error Logs<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Check your website&#8217;s error logs for messages that occurred at the same time as the Error 520 event.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Look for:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>PHP fatal errors<\/li>\n\n\n\n<li>Memory limit errors<\/li>\n\n\n\n<li>Timeout errors<\/li>\n\n\n\n<li>Application crashes<\/li>\n\n\n\n<li>Web server configuration issues<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">For WordPress websites, enabling debug logging can help identify the exact cause.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Check_Firewall_Configuration\"><\/span>Check Firewall Configuration<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A common cause of Error 520 is a firewall blocking Cloudflare&#8217;s requests.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Make sure:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Cloudflare IP ranges are allowed.<\/li>\n\n\n\n<li>Security tools such as ModSecurity are not blocking Cloudflare traffic.<\/li>\n\n\n\n<li>Rate limiting rules are not affecting Cloudflare requests.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">If your server blocks Cloudflare&#8217;s IP addresses, visitors may receive Error 520 even though the website appears to be online.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Verify_SSL_Configuration\"><\/span>Verify SSL Configuration<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Incorrect SSL settings can cause communication issues between Cloudflare and the origin server.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In Cloudflare, navigate to:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>SSL\/TLS \u2192 Overview<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The recommended setting is usually:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Full (Strict)<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This requires a valid SSL certificate on the origin server.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Avoid using Flexible SSL unless absolutely necessary, as it can create redirect loops and other unexpected issues.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Disable_Problematic_Plugins\"><\/span>Disable Problematic Plugins<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If you use WordPress, Joomla, PrestaShop, or another CMS, a plugin or extension may be causing invalid responses.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Temporarily disable:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Security plugins<\/li>\n\n\n\n<li>Caching plugins<\/li>\n\n\n\n<li>Redirect plugins<\/li>\n\n\n\n<li>Performance optimization plugins<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Then test the website again.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Check_Server_Resources\"><\/span>Check Server Resources<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If the server runs out of resources, applications may fail to generate proper responses.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Check:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>CPU usage<\/li>\n\n\n\n<li>Memory usage<\/li>\n\n\n\n<li>PHP worker limits<\/li>\n\n\n\n<li>Entry processes<\/li>\n\n\n\n<li>Disk space<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">A server under heavy load may generate intermittent Error 520 messages.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Verify_the_htaccess_File\"><\/span>Verify the .htaccess File<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Incorrect rewrite rules or redirects can sometimes trigger unexpected responses.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you use Apache, temporarily rename your <code>.htaccess<\/code> file and test the website.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For WordPress websites, you can regenerate a clean <code>.htaccess<\/code> file by saving the permalink settings again.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Clear_Cloudflare_Cache\"><\/span>Clear Cloudflare Cache<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Cached responses may continue serving errors even after the underlying issue has been fixed.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In Cloudflare, navigate to:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Caching \u2192 Configuration \u2192 Purge Cache<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You can purge the entire cache or only the affected URLs.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Contact_Your_Hosting_Provider\"><\/span>Contact Your Hosting Provider<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If you cannot identify the cause, contact your hosting provider and provide:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>The affected URL<\/li>\n\n\n\n<li>The exact time the error occurred<\/li>\n\n\n\n<li>The Cloudflare Ray ID shown on the error page<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">The Ray ID helps administrators trace the request in server logs.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Summary\"><\/span>Summary<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Cloudflare Error 520 means Cloudflare successfully reached the origin server but received an unexpected or invalid response. The most common causes include PHP errors, firewall blocks, SSL misconfigurations, resource limits, and application-level problems. Reviewing server logs and checking firewall and SSL settings are usually the fastest ways to identify the source of the issue.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n<\/div>","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"template":"","format":"standard","manualknowledgebasecat":[12],"manual_kb_tag":[6580,7160,7161,7162,7163,7164,7165,7166,7167,7168],"class_list":["post-8574","manual_kb","type-manual_kb","status-publish","format-standard","hentry","manualknowledgebasecat-cloudflare","manual_kb_tag-origin-server","manual_kb_tag-cloudflare-error-52","manual_kb_tag-cloudflare-troubleshooting","manual_kb_tag-unexpected-response","manual_kb_tag-invalid-response","manual_kb_tag-server-error-logs","manual_kb_tag-firewall-configuration","manual_kb_tag-cloudflare-ip-ranges","manual_kb_tag-web-server-configuration","manual_kb_tag-ssl-settings"],"_links":{"self":[{"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/manual_kb\/8574","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/manual_kb"}],"about":[{"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/types\/manual_kb"}],"author":[{"embeddable":true,"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/users\/1"}],"version-history":[{"count":3,"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/manual_kb\/8574\/revisions"}],"predecessor-version":[{"id":8575,"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/manual_kb\/8574\/revisions\/8575"}],"wp:attachment":[{"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/media?parent=8574"}],"wp:term":[{"taxonomy":"manualknowledgebasecat","embeddable":true,"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/manualknowledgebasecat?post=8574"},{"taxonomy":"manual_kb_tag","embeddable":true,"href":"https:\/\/mybox.com\/help\/ro\/wp-json\/wp\/v2\/manual_kb_tag?post=8574"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}