Getting the 520 error frequently

I have a website on namecheap’s shared hosting and I started running Ezoic ads on it last year.

Ever since then, I frequently get the 520 error when I try to go on the site. I asked namecheap and they said there are no errors on their end.

I’ve also tried adding whitelisted ezoic IPs to my wp-config file, turning off the “awlays online” option, turning off cloudflare (this changes the error to a line that just says “origin error”) and some other suggestions in this post. Nothing has helped.

Do you guys think that too much traffic could be the problem? My website gets about 63000 pageviews/month and has a lot of images + ezoic ads, all on shared hosting.

Could that be causing the website to time out and showing the 520 error?

Thank you

I was getting this error on GoDaddy hosting over the weekend. GoDaddy did something that fixed it at 7pm yesterday until a few hours ago it returned. Maybe it is more of a cloudflare problem than just GoDaddy as I assumed.

1 Like

That’s quite impressive for shared hosting, and using eZoic, may I ask do you have a cache for your WordPress enabled? :thinking:
And you also use Cloudflare over all that? :thinking:

Using eZoic, either with or without Cloudflare, I am 100% sure you cannot have WordPress cache due to eZoic WordPress plugin deactivating all existing cache plugins - see it in action in their code (eZoic WordPress plugin) here:

  • ezoic-integration – WordPress Plugin Repository

  • ezoic-integration -> includes -> class-ezoic-integration-deactivator.php

  • ezoic-integration -> includes -> class-ezoic-integration-cache-integrator.php

  • ezoic-integration -> includes -> class-ezoic-integration-compatibility-check.php

And the incompatibility list on the link below:

The list from above includes hosting providers too … shame on eZoic :face_with_hand_over_mouth: :shushing_face:

That’s what I assume is your issue with 520, while having all that traffic/pageviews directly hitting the “shared hosting” which obviously cannot handle it (PHP).

I see two possible solutions:

  1. keep eZoic and get to some better hosting package like VPS instead of shared hosting, but again, you cannot have a cache with your WP installation, and I am afraid neither Cloudflare cannot help a lot here

  2. remove eZoic, and have performance, speed, cache, security, etc.

At least, wasn’t working for me in combination as WordPress (with W3TC cache - all of them active including Page Cache and Cache Everything on Cloudflare) + eZoic ads integrated with Cloudflare Pro 6-7 months ago on shared hosting / dedicated server.

1 Like

Thanks for the info I checked out your links.

I’m using the W3 total cache plugin and have it integrated with Cloudfare. One of your links said that it’s compatible with Ezoic so I don’t think that’s the problem.

I don’t use the Wordpress Ezoic plugin because a lot of people have issues with it. Instead, I integrated my site using the Cloudflare method.

I remember my site was always slow even before Ezoic. But only after I started using Ezoic I was getting the 520 error a lot.

I think you’re right, it’s just shared hosting not being able to handle all the traffic + ads + images. But I wanted to try and rule out other problems before I upgrade the hosting to VPS.

I don’t want to remove ezoic cause it’s making me pretty decent moeny off that site even though it doesn’t load half the time :rofl:


We typically see 520 errors accompanied with errors in our logs indicating connection timeouts. These usually indicate that your origin web server was having issues during this period which caused us to generate those 520 errors.

  1. Your web server or networking equipment (Firewall, Load Balancer) reset the TCP connection after it was established. Sometimes when a web server crashes it will reset the connection. Check your web server error log for the timescale that the error occurred in and look for any error messages.
  2. Your web server returned an invalid response that exceeded our limits. Often this can happen if your web server is returning too many/too large headers. This is often caused by runaway scripts that return too many cookies, for example. The Code Igniter PHP framework has some known bugs around this too.

In these cases, it’s a good idea to then confirm with the hosting provider that there aren’t any application crashes or other issues that could be causing these response.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.