What is “Failed to load resource: net::ERR_BLOCKED_BY_CLIENT” and how to fix it

Blog Problem Solving

This article goes through "Failed to load resource: net::ERR_BLOCKED_BY_CLIENT" and tries to fix it

Today we try to analyze the error that appears on the browser inspector and that is a bit tricky to fix and we try to understand what is causing the error, the error is called “Failed to load resource: net::ERR_BLOCKED_BY_CLIENT“. This error is always followed by an URL, this URL is the link that has been blocked by the client (by your browser in this case), basically, the browser is saying that it can’t open the displayed URL because something on your browser or on your computer is blocking the URL for security reason.

For this error we could have two possible scenarios, the first is when the browser is blocking an external link, the second is when the browser is blocking a remote link.

If the error appears on external URLs.

If the error is related with external links, most likely the error is caused by an ad blocking browser extension, like AdBlock Plus type of extension, those type of extensions that blocks the annoying commercials that we daily come across often and often in these days. To be sure that your ad-blocking extension is causing the error I suggest to try to get to the same website through different browsers or try to deactivate the extension and see if the error appears again.

The best solution is to deactivate temporarily the extension. In order to do that on Google Chrome, please right-click on the extension icon on your browser and click on “Remove from Chrome”. Using the incognito version of the browser could be a temporary solution as long as the incognito version of the browser doesn’t load the browser extension.

If the external file that you are loading on your website is not a commercial, probably the external URL contains a keyword (or a series of keywords) that triggers the ad-blocking extension. The ad-blocking extensions use regular expression in order to check if an external URL contains certain words, such as “advert”, “ad”, “double-click” and “click” etc, so your browser extension could block the external URL like “googleads.g.doubleclick.net/pagead/id or static.doubleclick.net/instream/ad_status.js“, even if they are not commercial URLs.

So in this case I suggest you check your external URL file and remove all the words that can be seen as commercial/advertisement keywords..

If the error is related to the internal URL of the files that you are downloading.

In this case, you should go through again the code that you have generated. As we mentioned above, the ad-block extension is a regular expression that blocks certain URLs based on keywords, those keywords can be contained not only in the HTML code but also in files, file names, CSS files, JS files, images, image alt, etc… Those keywords can be “advert”, “ad”, “DoubleClick”, “click”, “advertise” etc In this case, you need to replace the suspicious words from your website, please be sure that those words don’t appear on file names, HTML tags, CSS, and in any part of your code and links.

For example, if the main image of your page is called “advertise-with-us.png”, the image will be blocked, if your CSS contains the classes “.advertise-with-us” of the IDs “#advertise-with-us” the whole CSS file will be blocked.

Hope this can be useful.

Click to Leave a Comment

You May Like

How to animate HTML elements and slide them in on mouse scroll using CSS and Javascript Today I want to animate a bunch of HTML elements and create an animation that moves them inside the same parent DIV once the elements are in the viewport, so only when the elements are visible to the users. […]

August 29, 2023

This tutorial will show you how to change your website cursor to any CSS shape and change the shape on hover on certain HTML elements. I have seen a lot of tutorials online about changing the HTML cursor to an SVG icon or to a PGN icon. In my case, I would like to change […]

October 15, 2022

Woocommerce Min Max Checkout is a plugin that extends your Woocommerce e-commerce in order to give you the possibility to set the minimum or maximum checkout amount or in order to set a minimum or maximum order quantity on the cart or checkout pages. With Woocommerce Min Max Checkout you can also set e customizable […]

February 12, 2022