1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-09-14 23:12:28 +02:00
uBlock/README.md

176 lines
6.9 KiB
Markdown
Raw Normal View History

2014-06-23 02:00:34 +02:00
# µBlock for Chromium
See [Change log](https://github.com/gorhill/uBlock/wiki/Change-log) for latest changes.
2014-06-24 06:28:46 +02:00
An efficient blocker for Chromium-based browsers. Fast and lean.
2014-06-23 02:00:34 +02:00
2014-06-26 18:48:32 +02:00
<p align="center">
Chromium on Linux 64-bit<br>
<img src="https://raw.githubusercontent.com/gorhill/uBlock/master/doc/img/ss-chromium-2.png" />
</p>
2014-06-23 02:00:34 +02:00
2014-06-26 18:48:32 +02:00
<p align="center">
Opera 22 on Windows 7 32-bit<br>
<img src="https://raw.githubusercontent.com/gorhill/uBlock/master/doc/img/ss-opera-1.png" />
</p>
2014-06-26 18:40:52 +02:00
2014-06-26 18:49:32 +02:00
<sup>The above screenshots were taken after visiting many [reference benchmark](https://github.com/gorhill/httpswitchboard/wiki/Comparative-benchmarks-against-widely-used-blockers:-Top-15-Most-Popular-News-Websites)
2014-06-26 18:48:32 +02:00
links plus a bit of random browsing. All blockers were active at the same time,
thus they had to deal with exactly the same workload. Before the screenshots were
2014-06-24 17:10:13 +02:00
taken, I left the browser idle for many minutes so as to let the browser's
garbage collector kicks in. Also, after a while idling, it's good to open the dev
console for each extension and force a garbage collection cycle by clicking a couple of times
the trashcan icon in the _Timeline_ tab (this caused a ~15MB drop for µBlock and Adguard in Opera)
2014-06-27 00:11:57 +02:00
as garbage collectors sometimes work in a very lazy way, so I did this for each extension.</sup>
2014-06-24 17:10:13 +02:00
2014-06-28 04:54:17 +02:00
**More:** [µBlock vs. ABP: efficiency compared](https://github.com/gorhill/uBlock/wiki/%C2%B5Block-vs.-ABP:-efficiency-compared)
2014-06-28 04:53:17 +02:00
2014-06-26 17:26:00 +02:00
#### Dispelling a few myths flying around
2014-06-26 01:58:18 +02:00
2014-06-28 07:15:57 +02:00
##### "µBlock does not support element hiding".
2014-06-28 07:19:32 +02:00
Yes it does. Try entering `twitter.com##body` in the _"Your filters"_ text area
and visit twitter.com: the page will be blank.
2014-06-28 07:15:57 +02:00
What it doesn't support [yet](https://github.com/gorhill/uBlock/issues/4),
2014-06-26 02:16:17 +02:00
is the UI counterpart to "element hiding", i.e. being able to click on an element
to extract filters out of it.
2014-06-28 07:15:57 +02:00
##### "The memory usage isn't actually ABP's fault, _EasyList_ is like 40,000+ lines of rules that all have to be parsed by ABP".
µBlock also parse _EasyList_, _EasyPrivacy_, _Malware domains_ lists,
2014-06-28 07:14:55 +02:00
and _Peter Lowes's Ad server_ list out of the box and yet uses less than half the
2014-06-26 02:05:22 +02:00
memory of ABP.
2014-06-28 07:19:32 +02:00
##### "µBlock has all the features ABP has!"
2014-06-28 07:15:57 +02:00
No it doesn't. There are things ABP can do which µBlock can't at this time. I will
2014-06-27 17:10:55 +02:00
consider all feature requests, but I will implement only those which do not jeopardize µBlock's
defining traits: lean, efficient and minimalist.
2014-06-26 01:58:18 +02:00
Filters with the `$popup` option are ignored. At time of writing, I see 558 such
filters in _EasyList. Chromium comes with a built-in popup blocker, which can be enabled
in the settings.
Filters with the `$elemhide` option are ignored. At time of writing, I see 50 such
filters in _EasyList_. The purpose of these filters is to disable cosmetic filters on
specific site.
2014-06-26 01:58:18 +02:00
#### Regarding reviews in various web store
2014-06-25 04:45:52 +02:00
2014-06-26 18:36:46 +02:00
- [My answer to web store reviews where appropriate](https://github.com/gorhill/uBlock/wiki/My-answer-to-web-store-reviews-where-appropriate)
2014-06-25 04:45:52 +02:00
2014-06-26 01:58:18 +02:00
#### Some articles about the origin of the source code behind µBlock
2014-06-24 06:38:26 +02:00
2014-06-24 06:39:37 +02:00
- [Net request filtering efficiency: HTTP Switchboard vs. Adblock Plus](https://github.com/gorhill/httpswitchboard/wiki/Net-request-filtering-efficiency:-HTTP-Switchboard-vs.-Adblock-Plus)
- [Adblock Plus memory consumption](https://github.com/gorhill/httpswitchboard/wiki/Adblock-Plus-memory-consumption)
2014-06-24 06:38:26 +02:00
2014-06-23 02:00:34 +02:00
## Installation
2014-06-24 04:08:05 +02:00
From the [Chrome store](https://chrome.google.com/webstore/detail/µblock/cjpalhdlnbpafiamejdnhcphjbkeiagm),
2014-06-24 07:55:32 +02:00
or [manually](https://github.com/gorhill/uBlock/tree/master/dist).
2014-06-23 02:00:34 +02:00
2014-06-24 06:38:26 +02:00
To benefit from the higher efficiency, it is of course not advised to use an
inefficient blocker at the same time. µBlock will do as well or better than the
popular blockers out there.
2014-06-24 16:52:44 +02:00
## Documentation
2014-06-24 17:20:15 +02:00
I think it is pretty obvious, except for this I suppose:
2014-06-24 16:52:44 +02:00
![Popup](https://raw.githubusercontent.com/gorhill/uBlock/master/doc/img/popup-1.png)
2014-06-28 07:21:04 +02:00
The big power button is to disable/enable µBlock **for the specific hostname
2014-06-24 16:59:18 +02:00
which can be extracted from the URL address of the current page**. (It applies to
2014-06-24 17:04:05 +02:00
the current web site only, it is **not** a global power button.) The state of the power
2014-06-24 16:59:18 +02:00
switch for a specific site will be remembered.
2014-06-24 16:52:44 +02:00
2014-06-24 16:26:31 +02:00
## Benchmarks
2014-06-24 15:37:20 +02:00
2014-06-24 16:26:31 +02:00
I ran my [reference benchmark](https://github.com/gorhill/httpswitchboard/wiki/Comparative-benchmarks-against-widely-used-blockers:-Top-15-Most-Popular-News-Websites)
to compare against other popular blockers.
2014-06-24 15:37:20 +02:00
Results -- figures are *3rd party* / *all*:
#### µBlock 0.1.0.4
* Domains: **66** / 67
* Hosts: 117 / 171
* Scripts: 239 / 321
* Outbound cookies: 8 / 42
* Net requests: 1,035 / 1,877
#### Adblock Plus 1.8.3
* Domains: **72** / 73
* Hosts: 124 / 177
* Scripts: 243 / 328
* Outbound cookies: 8 / 44
* Net requests: 1,041 / 1,913
#### Ghostery 5.3.0
* Domains: **83** / 84
* Hosts: 140 / 211
* Scripts: 239 / 343
* Outbound cookies: 17 / 57
* Net requests: 1,046 / 1,930
#### Adguard 1.0.2.9
* Domains: **89** / 90
* Hosts: 145 / 217
* Scripts: 262 / 349
* Outbound cookies: 18 / 68
* Net requests: 1,064 / 1,904
#### Disconnect 5.18.14
* Domains: **95** / 96
* Hosts: 163 / 239
* Scripts: 283 / 381
* Outbound cookies: 18 / 74
* Net requests: 1,087 / 1,989
#### No blocker
* Domains: **380** / 381
* Hosts: 566 / 644
* Scripts: 490 / 592
* Outbound cookies: 245 / 315
* Net requests: 1,950 / 2,871
2014-06-24 16:27:51 +02:00
The figures show the number of requests **allowed**, thus lower numbers are better.
The point is to show how many 3rd-party servers are hit on average after running
the reference benchmark (three repeats in the current instance).
2014-06-24 15:37:20 +02:00
2014-06-24 16:27:51 +02:00
The less hits on 3rd-party servers, the better. All blockers were configured
in such a way as to compare apples-vs-apples:
2014-06-24 16:20:52 +02:00
2014-06-24 16:23:03 +02:00
- **µBlock:** out-of-the-box settings -- no change.
2014-06-27 08:06:07 +02:00
- **Adblock Plus:** _"EasyPrivacy"_, _"Malware Domains"_ checked. _"Acceptable ads"_ unchecked.
2014-06-24 16:22:35 +02:00
- **Ghostery:** _"Advertising"_, _"Analytics"_, _"Beacons"_, _"Privacy"_ checked. _"Widgets"_ not checked. _"GhostRank"_ unchecked.
2014-06-27 08:06:07 +02:00
- **Adguard:** _"Spyware and tracking"_, _"Phishing and malware protection"_ checked. _"Social media"_ not checked. _"Acceptable ads"_ unchecked.
2014-06-24 16:23:03 +02:00
- **Disconnect:** out-of-the-box settings -- no change.
2014-06-24 16:20:52 +02:00
2014-06-23 02:00:34 +02:00
## About
µBlock is born out of [HTTP Switchboard](https://github.com/gorhill/httpswitchboard).
All the niceties of HTTPSB have been removed, and what is left is a straightforward
2014-06-23 02:09:30 +02:00
blocker which support EasyList and the likes, and also support host files.
Cosmetic filters ("element hiding") are supported.
2014-06-23 02:00:34 +02:00
There is nothing more to it. But it does what popular blockers out there do, at a
2014-06-23 02:14:54 +02:00
fraction of CPU and memory usage for the same blocking power.
2014-06-23 02:00:34 +02:00
2014-06-23 02:01:27 +02:00
Free. Open source. No donations sought. For users by users.
2014-06-26 22:32:35 +02:00
Without the preset lists of filters, this extension is nothing. So if ever you
really do want to contribute something, think about the people working hard
2014-06-26 22:33:36 +02:00
to maintain the filter lists you are using, which were made available to use by
all for free.
2014-06-23 02:00:34 +02:00
## License
2014-06-24 07:55:32 +02:00
[GPLv3](https://github.com/gorhill/uBlock/blob/master/LICENSE.txt).