Integrate Nano Defender with uBlock Origin to block Anti-Adblocker
A fairly common reaction to counter the rising use of adblockers is to implement anti-adblocking scripts to get Internet users to disable the content blocker on websites that rely on advertising revenue.
Update: Nano Adblocker and Defender ownership changed hand (except for the Firefox version), and the new version should be uninstalled immediately. We removed links to all versions except the Firefox version as a consequence.
Depending on how these scripts work, they may just display warnings when users visit the site with enabled adblockers or require that users deactivate the adblocker or whitelist the site to continue.
It is a race between creators of adblockers and anti-adblockers that does not address the bigger underlying picture in regards to advertisement on the Internet.
One option that uBlock Origin users have is to use Nano Defender's anti-adblocking capabilities. Nano Defender is an anti-adblock defuser by the creator of Nano Adblocker.
The process is a bit complicated for uBlock Origin, but it works without having to install Nano Adblocker in the browser of choice.
Integration in uBlock Origin
You find the instructions on GitHub, but here is everything explained in detail:
- Install Nano Defender in Chrome or Firefox.
- Enable the Adblock Warning Removal List in uBlock Origin. It is a list that is already available in uBlock Origin but not enabled by default. Click here to do so.
- Subscribe to the Nano Defender Integration filter list. The list is not already available, but you can subscribe to it with a click as well.
- The next step requires that you make a configuration change in uBlock Origin's configuration. You need to add a custom resource list in the advanced settings.
- Open the Settings of uBlock Origin.
- Check the "I am an advanced user".
- Click on the settings icon next to it that appears when you activate the option.
- Locate the variable userResourcesLocation and replace the initial value "unset" with https://gitcdn.xyz/repo/NanoAdblocker/NanoFilters/master/NanoFilters/NanoResources.txt
- Click on "apply changes"
- Close the tab.
- Subscribe to the Nano Filters list with a click on this link.
- Subscribe to the Nano Filters Whitelist list with a click on this link.
Most anti-adblocking scripts should be blocked automatically once you have changed the configuration of uBlock Origin and integrated the custom filter lists in the extension.
A quick test on several sites that use anti-adblocking functionality confirmed that this worked just fine at that point in time. The sites would load without the adblocking notification that they display normally when using adblocking extensions.
The lists get updated automatically and everything should work without you having to do anything form that point onward.
It is possible that you may run into connection issues with some sites that use anti-adblockers. It is still possible then to disable uBlock Origin, or, report the issue to have it addressed by the extension developer.
Now You: What is your take on sites using anti-adblockers that notify or block users with adblockers?
Just checking, is step 4 incorrect in this?
On the github page it states to replace “unset” with “https://gitcdn.xyz/repo/NanoAdblocker/NanoFilters/master/NanoFilters/NanoResources.txt”
You are right, thanks!
I have “https://cdn.rawgit.com/NanoAdblocker/NanoFilters/master/NanoFilters/NanoResources.txt”
Is it old?
No, that is correct. You need to add that line for uBlock Origin to register NanoAB filters.
4. Locate the variable userResourcesLocation and replace the initial value “unset” with
The new value should be “userResourcesLocation” correct?
Also, the ‘Adblock Warning Removal List’ one click link does not work for some reason. The popup dialogue appears but nothing gets added to the Custom filter list. The rest are working fine.
Thanks for this great article, was desperately looking for a way to deal with those annoying “Diable Ad-Blocker to continue” prompts.
No it is a different value, you may see the old because of caching. It is this: https://gitcdn.xyz/repo/NanoAdblocker/NanoFilters/master/NanoFilters/NanoResources.txt
EDIT: The one click link works fine now.
Ummm, I think step 4 is wrong the way you have written it.
For firefox, we have now nano adblocker & nano defender available xpi:
If I want to use nano defender, i’ll install nano adblocker instead of uBO.
Step 3.4 is missing some critical information that is present in the GitHub page.
What? …The only difference I can see is: Go to uBlock Origin dashboard to select Settings
No thanks, uBO can take care of anti-adblocking scripts just fine. Report all anti adblock issues here — https://github.com/uBlockOrigin/uAssets/issues
Ironic and laughable that it’s coming from you who hosted anti adblock before on ghacks — https://github.com/uBlockOrigin/uAssets/issues/574
Step 3.4 :
Locate the variable userResourcesLocation and replace the initial value “unset” with https://gitcdn.xyz/repo/NanoAdblocker/NanoFilters/master/NanoFilters/NanoResources.txt
OK, corrected already.
Great article. Of course I’ve subscribed to Nano integration/Anti-Adblock filters, even if I seldom encounter messages asking or requiring to disable the adblocker, but I don’t visit many different sites.
Some anti-adblock filters were already active :
Nano Defender Integrationâ€‹â€‹â€‹â€‹â€‹ : 2,652 used out of 2,671â€‹â€‹
â€‹â€‹Nano Filtersâ€‹â€‹ : â€‹â€‹â€‹91 used out of 181â€‹â€‹
â€‹â€‹Nano Filters – Whitelistâ€‹â€‹ : â€‹â€‹â€‹0 used out of 1â€‹â€‹â€‹
What is my take on sites using anti-adblockers that notify or block users with adblockers?
1- I don’t feel ‘revolted’ that sites notify the user of his adblocker.
2- I feel irritated that a site blocks users who don’t disable their adblocker for them.
3- I never make exceptions for sites, for the simple reason that doing so wouldn’t change much or even anything given that the big advertizers are blocked here system-wide via Hosts entries managed by the ‘Acrylic DNS proxy’ application as well as with the ‘Peerblock’ application, the latter decried by some and yet efficient, especially with the subsciption lists ($10/year).
As Martin states it in the article,
“It is a race between creators of adblockers and anti-adblockers that does not address the bigger underlying picture in regards to advertisement on the Internet.”
And the race goes on.
mm I think Nano Defender does a great job, uBlock Origin by itself can’t stop all anti-ad blocking scripts :).
Clearly ubo works great when you add nano blocker, nana blocker, nanny blocker and granny blocker. I mean my PC crashed but stricly no ads now.
Hahahahaha, that was funny… God job! :).
Added to uBlock Origin.
Great! I can watch bild.de again, although I never want to. ðŸ˜‚ðŸ˜‰
@Thorky, your comment got me to test bild.de and despite NanoDefender’s integration to uBO …
“Warum sehe ich BILD.de nicht?
Ein Plugin in Ihrem Browser beschÃ¤digt die Funktion der Webseite, deshalb kÃ¶nnen wir Ihnen keinen Zugriff auf die Inhalte gewÃ¤hren.
MÃ¶glicherweise nutzen Sie Ublock Origin oder ein anderes Adblocker Plugin. Falls dies der Fall ist, versuchen Sie bitte es zu deaktivieren.”
Warum, sag, warum?! But I think bild.de is one of those tough sites…
EDIT … sorry, my mistake (“he goofed again…”) : I use uBO with disabling by default 3rd-party and 3rd-party scripts, so granting bildstatic.de on bild.de (noop) allowed uBO and its rules to apply.
To be noted concerning uBO : some filters apply only when specific 3rd-party sites are called, as for bild.de above.
Ich habe auch bild.de als Test-Seite verwendet und bei mir klappt das freischalten nicht.
was mache ich falsch?hat jemand ein tip fÃ¼r mich?
I’m going to give it a try. I disable adblocking for sites I want to support, but if a site prevents me from finding out whether it’s worth supporting in the first place, this might come in handy. And, as Martin pointed out, if something goes haywire, you can always just disable uBlock Origin for the page or site … which is what you would have had to do anyway. I consider this a worthwhile tip.
I can’t run uBlock Origin. Every time I try to save a Web page, the page fails to save. Clicking retry makes it complete. I traced this to uBlock. So now I don’t run any ad-blocker because I save a lot of Web pages and it’s just too much work to keep saving and resaving due to some adblocker’s incompetence.
I find that NoScript enables me to kill most ad servers and I have a specific Youtube adblocker to block Youtube video ads. I can live with the remaining ads that fill in the sides of Web pages.
Have you tried SingleFile? It works great for me. https://github.com/gildas-lormeau/SingleFile
@Richard Steven Hack I don’t recommend browsing the Internet (or surfing) without ad-blocking software. uBlock Origin works seamlessly for me, even when saving changes, so please report those issues to the uBlock Origin developer to get them addressed properly. Thanks.
Owe you a beer, tanks.
It may be obvious, but some jumping right to those instructions near the bottom of the (linked) page may overlook the need to actually install Nano Defender, which is mentioned at the top.
Thanks, Rick. It wasn’t clear to me from the present article that installing Nano Defender was required. To my knowledge, Nano Defender is not available for Pale Moon or Basilisk. I don’t know whether the WebExtension port for Firefox Quantum works in Waterfox.
I think you may have it backwards. I don’t think you need to install Nano anything if you choose to follow the instructions in this article.
It’s possible, but if you read the Github page from the top, it’s hard to escape what I quote below. “Extra” steps for uBO means that the steps you’re referring to are not the sum total of what you have to do, they’re additional. And the only thing they could be additional to is the installation of Nano Defender.
“Nano Defender can only protect either Nano Adblocker or uBlock Origin, and will prioritize Nano Adblocker.
Get Nano Defender for Chrome or Chromium
****If you are using uBlock Origin, there are a few extra installation steps to follow.****”
I stand corrected. Martin updated the article to reflect what you wrote. Thanks.
So awesome. Thank you Martin.
It does change anything. Try here :
@Pierre, whatever the filters there will always be exceptions.
For your link you can add this to uBO / My filters :
Without the leading http://
Yes, it works, thks !
On Chrome/Chromium, Nano Adblocker + Nano Defender is considerably better than uBO (or uBO + Defender). It is a uBO fork of course, but the improvements and added features really stand out. I hardly ever have to unbreak sites while uBO has me adjusting it constantly.
On Firefox, it’s less convienient to install having to get it from GitHub, but once you install the pair they do update like normal addons so it’s worth the trouble. Especially as Nano does the job with almost no impact on page load speed and the reliability is rock solid. I’ve yet to actually visit a site where the blocking has been detected.
I agree. @Martin, by the way latest W10 updates destroyed all my file associations, so bad. :(
And it is also faster than UblockOrigin in Chrome 72, including while loaded with all the filters selected at once. I always needed to disable some filters of UblockOrigin to gain some loading speed in a lot of very complex pages. However now Nano Adblocker is able to perform really nice its duty with all the filters on. A really good UblockOrigin fork so far so good imho.
I use uBO’s official resource list :
I used to know Nano’s developer (jspenguin?) was a bit of *hostile* to FF (and ditched the FF version of his addons and focusing on Chrome), so I’ll stick to uBO. But it’s more suitable to choose Nano Adblocker if you want to deploy Nano Defender.
“The Tool will only collect your data when you use it, and will not connect to remote servers before the “Send” button is clicked.”
The whole thing is to diagnose a problem. If you don’t use issue reporter tool, then they won’t collect data.
Here’s how I deal with Adblockers on FireFox.
Open two tabs.
1st tab: Open blocked site > turn off uBlock Origin to enter site, once in,
2nd tab: Use it to go to Add-ons, then turn UBlock back on.
Go back to tab #1 and enjoy the content.
This is not working on inoreader.com
@Karbi, I don’t encounter any anti-adblocker on your site’s homepage.
You have to be on the reader page. The homepage doesn’t have anything on it.
Thanks for the nice, easy-to-follow guide. Are there any potential risks/problems when using this method?
The only specificity of this set of 3 Nano Defender filter lists compared to what we know of adding our own (uBO / Dashboard / Filter Lists / Custom – Import…) is what is described in the article’s step 3.4 : “Locate the variable userResourcesLocation and replace the initial value [..]”
uBO provides detailed information about this userResourcesLocation setting:
Too technical for me, but your comment triggered my unsatisfied curiosity for this particular setting.
If anyone has the means to explain in simple words uBO’s article on this ‘userResourcesLocation’ setting he/she will be thanked proportionally to the explanation’s quality. LOL!
From what I can tell gorhill seems to despise Nano and its creator in general for essentially taking like 90% of his code to make “his own” adblocker, and then promoting it on uBO forums as being superior.
Is it necessary to install Nano Defender or is it not? (I’m not talking about Nano Adblocker; I’m talking about Nano Defender. The GitHub page seems to suggest that it is. This article seems to suggest that it isn’t.
Peter, yes it is. The review did not make it clear, I have added the step to make it clearer.
@Martin: Thanks; I appreciate the clarification. As a Luddite who still uses Pale Moon as his primary browser, I guess I’m I’m left out in the cold. Ah, well — maybe I’ll add it to Google Chrome, which I’m forced to use from time to time.
(Also, sorry for the missing closing parenthesis. My aging keyboard *does* sometimes miss keystrokes, but I’m pretty sure that one was on aging *me*.)
Pity it doesn’t work with ABP which is much simpler to use than uBlock Origin the latter of which is way too complicated for my decrepit grey matter.
This is not going to work with Pale Moon, as it is necessary to install Nano Defender.
My take is to close the tab and keep browsing away.
i have uBO but no Nano filters like in the picture above.
there is an issue with Opera developer 59 no sound on you tube
“..it works without having to install Nano Adblocker in the browser of choice.”
then step 1 says to install Nano
When I try to subscribe to lists on firefox I get “The address wasnâ€™t understood” error
What I noticed, sites that uses to use anti-adblockers step by step stop doing that. They understood people simply leaving the page and we get kind of different notice. A notice to appeal to our good will. Î¦uck ’em Î™’d say.
works like a charm, thanks for these easy steps (really like your just clic here steps ;))
Thanks for the clearly written tutorial, Martin Brinkmann.
Awesome! Thank you…
How do I subscribe to these lists on Firefox Mobile? I tried clicking or manually copying the url but that doesn’t work. On my PC I got it done, thanks!
The Tampermonkey scripts stopped working for me —but this did, and amazingly so! Thanks a lot
“What is your take on sites using anti-adblockers that notify or block users with adblockers?”
The commercial class has become brutal as apes, they bombard people with ads, polls and all kinds of stuff, through every channel they can get at. TV, electronic mailboxes, physical mailboxes, every type of screen, telephone. This all to the extent that people have to protect themselves against the bombardment, a bombardment which is also characterized by all parties trying with different means to become more louder and more visible..
This is at large a cultural problem, a cultural obsession with commercialism and marketing which makes of the world a market place, and of citizens mere consumers. It is basically very primitive and brutal, no matter the advanced technologies used.
Now, the commercial classes have even created a new moral rule which benefits their own class, which is that if you read something without paying, you have to ‘ pay’ for it by looking at advertisements. I.o.w., you have to reserve a place in your mind for the marketed images, or and you have to buy more stuff which you don’t really need.
These commercial classes are very smart, they know that people are very curious, and often bored, so they will collectively spend times reading all kind of junk and trivial stuff which is out there for free. Hence, they create markets by placing it there for free. The market of boredom and endless curiosity. The trick is here in the moral rule which they have created for their own advantage, a subtle moral command, implanted in the minds of people, using sophist reasoning.
Now the situation is pretty simple, if they put stuff online which costs money, they should put it behind a wall so that people can only read it when they pay for it. They are themselves responsible for protecting their wares. If they put it out there for free they have no reason to complain that people are not paying for it (by means of looking at advertisements, which on itself is a doubtful method of ‘paying’ anyway).
If they cannot earn enough money when they put it behind a paywall, then it is their problem, then there is no market for it, or the quality is not good enough.
If they block people who have ad blockers, it is their right, as a visitor with an add blocker, and what else as a means to avoid the bombardment of the commercial class, then you know they are targeting the sheeple, the consumerist work-slave masses.
What you see often these days is that they try to convince you to disable your ad blocker, then they play on your feelings. In general one should stick to the rule that in business, if the business cannot live from people who are wiling to pay in ordinary coin, the business is redundant and created and kept alive by doubtful means, means which are merely invented in order to extend the market, to add a bubble industry to it. This is not a healthy economic situation, economic practices which are not healthy should not be supported.
I have been using adblockers ever since they were invented. Couldn’t live without them. At work were I am not allowed to install them I just wont surf the net, I’d go crazy with all the ads.
I have been using adblockers since they were invented. Couldnt live without it. At work were I am not allowed to install stuff I just dont surf the web. I’d go crazy with all the ads.
Thanks for the fix!
Can you uninstall Nano Defender after this (I understand you may lose the auto-updation of scripts), or is uBO dependent on it?
Nano Adblocker has been left by its originator and taken over by unknown people.
So Nano Adblocker/Defender have become suspicious and dangerous.
Apparently Nano Defender has been compromised, and can’t be trusted anymore. I’m no expert, so here’s the link to my source:
none of the above 4 lists are getting added to my ublock origin. I have nano defender extension installed and working. When I click on the above 4 links (left-click) it shows window asking my confirmation to add that one, I allowed each time, but none of the 4 lists is appeaing on my ublock dashboard.
that manual change to unset I have done.
What I am doing wrong? What should I do to add the four lists?
shouI I uninstall nano defender and nano adblocker. I have kept both installed, but nano adblocker is kept disabled while nano defender is enabled.
Should I uninstall or disable one or both of them. I have ublock origin set up and working.
UBLOCK has BLOCKED them to be added its a hardcoded denial. Either they dont consent with the whole anti-adblocker removal thing (for legal reasons), they dont approve of using nano filters, or worse nano has in deed been compromised.
You can copy the links, convert the ASCII codes to their original characters (:// and /) and just add them to the filter list manually. :) The extension may have been compromised for collecting data because the development was taken over by a different company, but filters can’t collect data, so it’s not like it’s unsafe to use them. Also, the Edge store listing is still under control by the original developer, and the Firefox is an official port of that work. It’s the Chromium/Chrome store page that was taken over. See here for source: