Recent changes to this guide are listed at the end of the document.
First and foremost, use only uBlock Origin (uBO) by Raymond 'gorhill' Hill (here's the uBlock Origin page on the Firefox Add-ons website). While there may be some legitimate forks, there are also many ripoffs out there, including one named 'uBlock', and i would highly recommend avoiding them.
Following are my personal preferences for setting up uBlock Origin. There are no "best" settings since every use case is different, however i like to think they are generally sensible settings to start with. The configurations in the 2nd and 3rd columns of the table are intended to be used with the The Firefox Privacy Guide For Dummies! and the Firefox Configuration Guide for Privacy Freaks and Performance Buffs, respectively. In the former case the advanced mode option is disabled because i thought it might be too overwhelming for followers of the 'dummy' guide.
Regardless of which guide you are following, it is essential that you read the uBlock wiki with the exception of the Advanced-user-features section if uBO's advanced mode will not be enabled. If you are not following either guide i would suggest enabling the advanced mode option in order to leverage its dynamic filtering capability, as well as reading the Advanced-user-features section of the wiki.
Once uBO is installed, click its toolbar icon to reveal its popup user interface, then click the little sliders icon to reveal the "secret" Dashboard (i say "secret" because apparently some users don't know it exists). Following are the settings i recommend:
Settings not shown here are optional.
||'Dummy' guide settings
||Advanced guide settings
|Hide placeholders of blocked elements 1||disabled||optional|
|Show the number of blocked requests on the icon||enabled||optional|
|I am an advanced user 2||disabled||enabled|
|Disable hyperlink auditing||disabled||disabled|
|Block CSP reports||enabled||enabled|
|Uncloak canonical names||enabled||enabled|
|Disable cosmetic filtering||enabled||enabled|
|Block media elements larger than  KB||disabled||optional|
|Block remote fonts 3||disabled||disabled|
1 - If you are new to uBO and content filtering, you should probably not enable this option. Leaving this option disabled will sometimes provide a visual indication when something is blocked in the form of a placeholder where the object was, thus letting you know that something was blocked.
2 - This option may be enabled only after reading the Advanced user features section of the uBO wiki.
3 - Instead of blocking remote fonts globally and then allowing them per-site, you can automatically allow all 1st party fonts while blocking only 3rd party fonts. See the 'My filters tab' section below for more information. Novice users, or those that simply don't want to fool with filters for unblocking a 3rd party font needed for a given domain, may find it easier to set this to 'enabled' and then allow all remote fonts (1st and 3rd party) as needed from the uBO Dashboard.
<noscript> HTML tags. A potential problem with this is that some page elements that might have been displayed had the
'Filter Lists' tab
|Auto-update filter lists||enabled|
|Suspend network activity until all filter lists are loaded||enabled|
|Parse and enforce cosmetic filters||disabled|
|Ignore generic cosmetic filters||enabled|
|uBlock filters – Badware risks||enabled 1|
|uBlock filters – Privacy||enabled|
|uBlock filters – Resource abuse||enabled|
|uBlock filters – Unbreak||enabled|
|AdGuard Mobile Ads||disabled 2|
|AdGuard Tracking Protection||disabled|
|AdGuard URL Tracking Protection||enabled|
|Block Outsider Intrusion into LAN||enabled|
|Online Malicious URL Blocklist||enabled|
|Phishing URL Blocklist||enabled|
|PUP Domains Blocklist||enabled|
|AdGuard Social Media||disabled|
|EasyList Cookie||disabled 3|
|uBlock filters – Annoyances||enabled|
|Dan Pollock’s hosts file||disabled|
|Peter Lowe’s Ad and tracking server list||enabled|
|ClearURLs for uBo (unofficial) 4||https://raw.githubusercontent.com/DandelionSprout/adfilt/master/ClearURLs%20for%20uBo/clear_urls_uboified.txt|
1 - Optional for Linux users, highly suggested for non-technical Windows users
2 - Enable if using Firefox on a mobile device
3 - Enabling this list will hide a lot of those idiotic cookie notices however this list is already included in the Fanboy’s Annoyance.
5 - Removes tracking parameters from URLs. This list replaces the basic functionality of the Clear URLs add-on. For a description see this.
Don't worry about the 'Regions, languages' section unless you browse sites in languages other than English in which case you'll want to enable those languages.
There are millions of additional filter lists available for uBO, however i strongly advise you to be very careful about what ones you add, if any. In my experience the default filter lists offered by uBO are quite sufficient for general web browsing and adding more will use more memory, slow things down and potentially cause more conflicts and breakages.
'My filters' tab
You might wish to disable the 'Block remote fonts' option on the 'Settings' tab add the following to the 'My filters' settings instead. Depending on which line you uncomment (remove the ! ) you can allow all 1st party fonts while blocking all 3rd party fonts, or block all 3rd party fonts except for a single domain, or block all 3rd party fonts except for multiple domains. As written, the code below will allow all 1st party fonts while blocking all 3rd party fonts. All lines beginning with ! are comments and are not read by uBO. Only uncomment one line.
! >>> UNCOMMENT ONLY ONE LINE AND EDIT IT AS NECESSARY <<< ! uncomment the line below to allow 1st party fonts + block 3rd party fonts (default): *$font,third-party ! uncomment the line below to allow 1st party fonts + allow 3rd party fonts for a single domain (example.com): !*$font,third-party,domain=~example.com ! uncomment the line below to allow 1st party fonts + allow 3rd party fonts for multiple domains: !*$font,third-party,domain=~example.com|~example2.net
'My rules' tab settings
If you are following the Firefox Configuration Guide for Privacy Freaks and Performance Buffs or otherwise using uBO on its own, and you have enabled the 'I am an advanced user' setting, you can optionally replace the default
behind-the-scene rules on the 'My rules' tab with the the following, however understand that these filters can break some websites for which you may need to add exceptions by using uBlock's logger feature:
no-large-media: behind-the-scene true behind-the-scene * 1p-script block behind-the-scene * 3p block behind-the-scene * 3p-frame block behind-the-scene * 3p-script block behind-the-scene * image block behind-the-scene * inline-script block
If you are using the LocalCDN add-on you will need to add some rules to the 'My Rules' tab in the uBO Dashboard. The rules can be found in the preferences section of the LocalCDN add-on from where you will copy the rules specific to uBlock and paste them on a new, blank line in the 'Temporary rules' section of the 'My Rules' tab. Make sure to save and commit the changes. When adding the rules, be sure to remove any conflicting rules for the same domains if there are any (there won't be if you're starting fresh).
If you are running uBO with its 'I am an advanced user' option enabled in order to activate dynamic filtering, i recommend setting the following rules in the 'Global rules' column of the popup interface:
If you decide to block '3rd-party' (all 3rd party content) globally, uBO will not be able to update its filter lists until you create a 'noop' rule for the Filter Lists settings page which you can do from the dashboard pop-up interface while viewing the Filter Lists page.
- updated settings and information for the custom filter lists in the 'Filter Lists tab' section
Note that both reader and my comments, while they may have been accurate at the time, might not be inaccurate today. This is a highly dynamic environment so please verify the accuracy of a comment should you wish to utilize it. Failing that, ask me and i'll give it a crack.
154 thoughts on “uBlock Origin Suggested Settings”
Hello. I tried looking at the uBO wiki but couldn’t find an answer (at least in plain view, I’m still a newbie) so I ask you: what does “no-large-media: behind-the-scene true” do and should I set it to true if I have the “Block media elements larger than …” option enabled?
Thank you and keep up the good work.
from the wiki…
Behind the scene network requests
i’m really not sure how to advise regarding this setting – i have it set to ‘false’ for potentially less breakage, but that may not be necessary
behind-the-scene stuff is, as it says, requests that uBO can’t associate with a tab (doesn’t know where the request originated) – the ‘Block media elements larger than’ option is for media elements that CAN be associated with a tab – this sets the default for the per-site switch on the main pop-up, ‘click to block large media elements for this site’ – so if you don’t want media elements larger than ‘x’ to be loaded for a given site, you can specify a size and then use the per-site switch
personalty, i wouldn’t bother unless you need to conserve bandwidth – most all this stuff will be blocked by default anyway if you have blocked JS globally (which you should) – then you can allow JS per-site or certain JS (such as for youtube) globally
No large media elements
Actually I have it enabled not for bandwidth saving but because I have an 11 years old laptop running Win7 (can’t install a Linux distro on it thanks to the graphic chip…) with only 4gb of ram and I thought that would help in terms of performance. Dunno if this assumption is correct though.
I guess I’ll have to start getting used to disable js and whitelist sites I uses regularly.
Another thing: I dumped LocalCDN because I read it’s basically redundant with the arkenfox user.js (and also because like I said the less stuff I have installed the better) but I noticed I have to whitelist a lot more stuff in uBO now to make sites work (Cloudfare mostly), so do you think I should go back to it or keep whitelisting them as I use said sites?
Linux is great for older machines i’ve heard (over and over) – as far as the graphic chip, you *should* be able to use the open source driver at least
i don’t think (really not sure though) blocking large media will help performance wise, but pages with large media might load faster
> I dumped LocalCDN because I read it’s basically redundant with the arkenfox user.js …
true, but sites relying on CDNs will likely take a bit longer to load since that content is no longer loaded locally
> … do you think I should go back to it or keep whitelisting them as I use said sites?
totally up to you – personally i still use LocalCDN for speed reasons and because i don’t think the redundant privacy hurts anything
I reinstalled LocalCDN after all and started getting used to hard blocking mode + JS disabled, it’s actually pretty comfy, pages finally load faster. Sure, the ‘My rules’ panel is loaded with lines now but it can’t be helped I guess.
>Linux is great for older machines i’ve heard (over and over) – as far as the graphic chip, you *should* be able to use the open source driver at least
I know, I have an even older netbook with Bunsenlabs on it and it goes like a true champ. Unfortunately the laptop I use regularly (and has a bigger screen too) is “infected” with the SiS Mirage 3+ 672 graphic chip and the 2 solutions I found (1: https://gist.github.com/fevangelou/46a2885233c45011ad5c8752f18eac73 , 2: https://linux-sis-driver.weebly.com/linux-ubuntu-distros-and-the-infamous-sis-chips/linux-driver-for-infamous-sis-671-672-771-772-717) don’t work no matter how many times I try… Oh well.
> JS disabled, it’s actually pretty comfy, pages finally load faster.
sure do, also most tracking and fingerprinting (and malware, pop-ups, etc.) require JS
so you’re using uBO without uMatrix i take it?
>sure do, also most tracking and fingerprinting (and malware, pop-ups, etc.) require JS
Well they load faster because there’s nothing left to load most of the times, hahaha
>so you’re using uBO without uMatrix i take it?
Yeah, I’m still at the stage of constantly learning how to use uBO properly. Also from the little I’ve read uBO can actually do a fair amount of the things uM does, so I feel comfortable using just one right now.
A question: have you ever thought of making a uMatrix setup guide just like this one? I know you basically already did in the Freaks Firefox guide but having a separate one would be nice.
> uBO can actually do a fair amount of the things uM does
it can, but if you want granular control uM is easier to work with IMO – actually i think it’s easier period, but it might be a good thing if you stuck with uBO for a bit and learned how to use it well – the wiki is a great resource and it actually covers some stuff that’s missing in the uM wiki
> have you ever thought of making a uMatrix setup guide…
i recommend uM in the advanced guide only, so no – i broke out the uBO guide from both config guides only because a lot of the stuff was redundant and i got tired of having to edit both guides every time i changed stuff for uBO in one of them
Last question: what’s the rationale you used on selecting these Filter lists? For example, the uBO wiki recommends the “Peter Lowe’s Ad and tracking server list” enabled for medium blocking mode and higher but you have it disabled in your guide?
that’s a hosts file list and they can be problematic for some reason – this is even discussed in one of the wiki’s i think – my choices are based on my experiences and pretty much never give me any trouble
It puzzles me, that the filterlists in UblockOrigin do not update automatically, even though auto-update is enabled. I noticed a while ago, but I don’t know for how long this has been the case. at one point after a manual update, I discovered 3 cookies set by some of these filterlists. I don’t recall which. normally I only allow cookies, if necessary. Any suggestions to why this happens and how to solve it?
odd, in my case the filter lists are auto-updating as they should
regarding cookies being set by a filter list, i didn’t even know that was possible – can you provide more detail, such as how you knew they were set by a filter list and perhaps their name(s)?
to see which cookies are being set by filter lists purge all caches then update list then look under Options-Privacy&Security-Manage Data… sorting it by Last Used
hmmm… not sure what to think of that – for the lists i use, cookies were set by…
i tried looking at these cookies with the browser console and i’m not seeing anything that looks nefarious to me – i suspect they are probably set in order to establish the time that the client last updated the lists, perhaps to avoid unnecessary concurrent downloads from the same client – that’s just a guess though and, frankly, i’m not concerned enough to look into it deeper, but if you do, let us know
thanks for reporting this
exactly the same cookies as mentioned by you, are set in my browser too.
Besides: am I supposed to activate “purge all caches” once in a while, given the fact that these filterlists do not auto-update? I’m not quite sure what the term means/involves in regards of UblockOrigin settings
you should not ever have to purge the filter lists cache and they should update automatically
i think the purge thing is for when you want to disable a list where purging will remove it from memory
when you purge, are you able to manually update this lists? and are you sure they are actually updated? – to test, disable your network connection, purge a list, click the ‘eye’ looking icon (view content) for the list and make sure the list is empty, then enable your connection and manually update and check the list again
enable the ‘I am an advanced user’ setting and you’ll see a gear icon appear right after that option – click that and then press Ctrl+F and enter:
and check those settings – here’s mine:
on a side note, try setting
dark… pretty cool
don’t forget to disable advanced mode
if that doesn’t straighten things out, let me know and we’ll dig deeper
I found all the mentioned asset settings as well as autoUpdateDelayAfterLaunch and with the same numbers. I think things might work as they should by now: when I hover over the clock-symbol all lists have been automatically updated after the date of my manual update.
I feel a bit uneasy about the cache purge action: it is not clear to me how to purge one list without disabling all the others. I will leave it be and cross my fingers for the update problem to be solved.
I searched for how to change theme color but couldn’t find where to do this. Is it the colorblind- help out -option in the settings?
you can’t purge a single list apparently – sorry, i didn’t realize that
to change the theme color, enable advanced mode and in the advanced settings change the value of
uiTheme– i didn’t look up what the possible values are, but i found that ‘dark’ works
regarding uiTheme, it says: unset.
am I to manually delete these 5 letters and afterwards type: dark?
if you want to change the theme, yes, replace ‘unset’ with ‘dark’ – 3 possible values are ‘light’ ‘dark’ and ‘unset’
ps: don’t forget to disable advanced mode if you weren’t already using it
please relax ;) this is not a new issue. Just a big Thank You for all your good work and guidance.
thank you Jane – same to you and yours :)
How do i block the pop up when visiting google (‘Before you continue…’ & youtube (sign-in) popup through uBlock?
by reading the uBO manual :)
I tried and no luck..also followed your write ups, no luck. I probably need to try the uMatrix route
i don’t use gaagle directly so i don’t know what pop-up you’re referring to, nor do i log on to ThemTube
Firefox has a built-in pop-up blocker and you could also use CSS if you know how – i use basically the same config as outlined in the advanced guide, less uMatrix (i’m testing without it), and i never see any pop-ups anywhere – i do see stupid CSS-styled overlays on occasion, but i destroy them with CSS
uBO also has an element hider function you might find useful
Sorry I should have linked it.
The add to my filter list method didn’t work in uBO
I’ll play around with the settings.
if you’ve set up uBO according to my guide, check that ‘element hiding’ is not disabled – uncheck ‘Disable cosmetic filtering’ in settings and on the filter lists tab, check “Parse and enforce cosmetic filters”
didnt still help, i’ll keep trying. Thanks
what doesn’t work? you can’t hide the pop-up, or the element hider in uBO doesn’t work?
Ah you mean to use use element hider. Yes that does work
your recommendations (and settings) do work for for example for translate.google com or maps.google com, but they don’t work for youtube.com. one still gets the “sign in to youtube” popup
i’m using uBO in advanced mode without uM and i never see a log-on pop-up – are you allowing ‘accounts.google.com’? if so, that may be why
if you don’t see that domain in the uBO pop-up, click the ‘+all’ label
the problem with youtube/google exists only if the users IP is in EU and while using Firefox.
using Brave browser there is no need to turn on uBlock at all as well as turn on built into the browser trackers&ads blocking or fingerprints blocking.
i don’t know what the YT pop-up looks like – if it’s a DIV layer, you can easily kill it with CSS – if it’s a page that forwards, you can possibly use a redirect
whatever the case, more people need to stop using the platform
The “Fanboy’s Enhanced Tracking List” filter got moved from the Privacy group to Custom, dunno what that means for the grand scheme of things though.
thanks for letting me know – i addressed the change and made a few other small edits
No problem. I’m not sure about this but if you fresh install uB0 will the Fanboy’s Enhanced Tracking List even be in the Custom group though?
glad you brought that up, i should’ve known better – no, it is not available by default on a fresh install – i removed it from the guide – also see: Removing Fanboy Enhanced Tracking
I use the ClearURLs addon but I just discovered this filter list: https://raw.githubusercontent.com/DandelionSprout/adfilt/master/LegitimateURLShortener.txt
Seems to be working pretty well, what do you think? I’m all for 1 addon installed less….
very interesting – thanks for sharing!
it’s very new and reading through the uBO issue you linked to, i’m not sure how well versed the author is in RegEx, so personally i think i’ll let the project bake a while before kicking the tires but, yeah, i too am all for dumping as many extensions as possible
I don’t know if it’s the author being inexperienced as you said or the fact that it’s a filter list and not an extension like ClearURLs but after using it for a whole day I can agree with you that it needs some serious polishing as I noticed it removes parameters for sites that have no tracking parameters in their urls thus rendering them almost unusable. I’ll stick with ClearURLs for now.
thanks for the update – i don’t think i’ve ever had anything break with ClearURLs so i don’t mind sticking with it
Another useful link I forgot to post earlier: https://github.com/DandelionSprout/adfilt/discussions/163
It seems uB0 dev also recommends this filter list.
Regarding Cname: I got the setting: “Uncloak canonical names” enabled; but I’m not quite sure whether I’m actually protected by cname-tracking or whether ublock “just” detects this kind of tracking and leave further action of how to deal with this up to me. The cname is not blocked=green, and when I open the logger no blocking here either as far as I can see.
i’m not 100% certain and i don’t have time to look into it at the moment, but i’m fairly sure that when you enable uncloaking you can prevent the tracking because, when you enable the setting, you’ll see hosts in the uBO pop-up interface that are colored blue and those are the ones that cname uncloaking exposes and therefore they can be blocked
The setting “Prevent WebRTC from leaking local IP addresses” has been removed since it is no longer necessary in modern browsers, except for Firefox for Android where the issue is still present.
thanks for mentioning that – i’ll update the guide accordingly
I would like to draw your attention to the fact that Spam404 filter list is discontinued and has been replaced in uBO with a total of three other filter lists against malware: Online Malicious URL Blocklist, Phishing URL Blocklist, PUP Domains Blocklist.
thanks for notifying me!!!
i updated the guide to reflect the change, plus made a few other changes/edits – see the Revisions section for details
I’ve tried the ‘My filters’ tab setting right now and allowed first party and blocked 3rd party fonts.
The issue I have is that this doesn’t only block fonts, but also icons?
For example if you switch to reddit.com https://postimg.cc/8jDcLsT1
What’s up with that? Is it a bug or a feature?
they’re not actually icons in the traditional sense – they’re “fonts”, but i’m not recalling the correct name at the moment
you can look at the logger and see where they’re coming from and then edit the filter accordingly, so then the filter becomes
on blocking remote fonts – i normally block third-party fonts. noticed you’re recommending blocking all fonts by default/using exceptions. are you able to elaborate as to what changed, or maybe point me to some documentation? note: not a question of validity.
filter lists – how does one figure out which filters to add, are necessary and/or whats redundant?
as usual – thank you.
breaking the thread rules:
yes to clown world.
if i’m understanding you correctly, nothing changed – i recommend blocking fonts in uBO settings -OR- don’t block them in settings and, instead, allow all 1st party fonts and block 3rd party using the filter
see: Per site switches and Ctrl+F
> filter lists – how does one figure out which filters to add, are necessary and/or whats redundant?
you don’t have to worry so much about redundancy – if you look on the Filter Lists tab you’ll see stuff like ‘EasyList 29,620 used out of 61,788’ (yours nums may be different) – this is because uBO is doing its magic and eliminating redundant filters
as for which lists to enable, that’s a harder question to answer – my selections are based on some degree of experience where, for example, i find EasyList to be plenty sufficient while other ad block lists have caused problems for me
next to all the list items are icons which you can click to gain more info about them
> breaking the thread rules…
rules? what rules? stray off-topic all you want
ps: i changed the remote font setting for advanced users and added a footnote for the Block remote fonts item in the ‘Settings tab’ section
> … this is because uBO is doing its magic and eliminating redundant filters
i neglected to mention that uBO is building its filter list by looking at all of the enabled lists, so in other words it will dump redundant filters across multiple lists – maybe that goes without saying but i just said it :)
— i recommend blocking fonts in uBO settings -OR- don’t block them in settings and, instead, allow all 1st party fonts and block 3rd party using the filter *$font,third-party–
alright. i read it wrong. good deal.
–rules? what rules? stray off-topic all you want–
it’s too big. everyone is at street level debating the name/function of street signs. a very small percentage of us are outside of things enough to ascend from the map and see where the highways and roadblocks reside. how it all fits together. we are in trouble.
to recognize this would create an environment where people would have to objectively look inward/outward. i.e. reality and critical thinking. people have been engineered at this point to avoid/deny it. it would be bad for business.
It’s redundant to set it to true as unset already enables it on Firefox, if you want you can mention the pref for Botnet, err, Chrome users, but since you’re focusing on Firefox I’d remove that bit from this guide. You’re choice obviously.
i don’t recall seeing that before in wiki – i think i’ll leave the setting in here anyway, just in case the default changes – thanks for letting me know though!
Shouldn’t this part of the text say “true” instead of what is intended: and change suspendTabsUntilReady to yes?
> Shouldn’t this part of the text say “true” i…
what part of the text?
‘Settings’ Tab -> First paragraph after Footnotes -> Line #3. I have copied actual text after the colon.
there’s no footnotes on the settings tab, nor any paragraphs – i don’t understand what you’re referring to
you mentioned something about suspendTabsUntilReady earlier – you can read about that here
Sorry about the goose chase. I think the value for SuspendtabsuntilReady can be unset, yes, or no whereas I’ve been using your old config where the value was set to true (see 22 Nov 2019 revision). Combine that with the comment below from panama_man, I guess it shows how much I implicitly trust your config :-) and have become lazy to not read man pages!
You can clear that part with the advanced user settings: “suspendTabsUntilReady to yes”
That option is no longer there.
Looks like the addon’s author moved that directly into the “filter list” tab: “Suspend network activity until all filter lists are loaded”
thanks for pointing that out – i appreciate it :)
how create a ‘noop’ rule (allow) for the Filter update Lists settings page
i’m not sure what you’re asking – can you be more specific
I think you mean this note above? NOTE: If you block 3rd-party globally or locally, uBO will not be able to update its filter lists until you create a ‘noop’ rule (allow) for the Filter Lists settings page which you can do from the dashboard pop-up interface while viewing that page.
1.open uBlock Dashboard
2.go to Filter lists page
3.open uBlock user interface popup while on Filter list page
4.click in Third column (local dynamic filtering rules) on the 3rd-party row (it should change to gray from pink or red)
I was just following this guide, as i had previously followed the Firefox privacy guide but it seems you have changed it since I last used it. Anyway I found that the dummy guide settings might need to be updated as some of those options come up with a triangle in uBlock stating out of date.
you just need to update the lists; settings > filter lists … then click the ‘update now’ button