Rules

You can edit rules to block sites in the options page, as well as in the “Block this site” dialog.

rule editor

You can write rules by match patterns or regular expressions.

Match patterns

Match patterns are URLs including wildcards. You can see the details in MDN web docs.

Here are examples of valid match patterns.

Pattern Example matches
*://example.com/*

(URLs hosted at example.com)
http://example.com/

https://example.com/hoge
*://*.example.net/*

(URLs hosted at example.net or its subdomain)
http://example.net/

https://foo.example.net/hoge
*://example.org/hoge/*

(URLs hosted at example.org and whose path starts with /hoge/)
http://example.org/hoge/fuga.html

Here are examples of invalid match patterns.

Invalid pattern Reason
*://www.qinterest.*/ * is not at the start. Use regular expressions instead.
<all_urls> Not supported.

Regular expressions

You can write more flexible rules by regular expressions.

Note that regular expression rules shall be regular expression literals in JavaScript, surrounded by / (e.g. /example\.(net|org)/).

Here are examples of valid regular expressions.

Regular expression Example matches
/^https:\/\/www\.qinterest\./

(URLs starting with https://www.qinterest.)
https://www.qinterest.com/

https://www.qinterest.jp/hoge
/^https?:\/\/([^/.]+\.)*?xn--/

(URLs including internationalized domain names)
http://例.テスト/

Here are examples of invalid regular expressions.

Invalid regular expressions Reason
^https?:\/\/example\.com\/ Not surrounded by /.
/^https?://example\.com// Inner / are not escaped.

Regular expressions for page titles

To block sites with specific titles, use regular expressions preceded by title.

For example, title/example domain/i blocks sites which titles include “example domain” in a case-insensitive manner.

Unblock rules

Match patterns or regular expressions preceded by @ mean that the specified sites are not blocked.

They can be used to unblock sites that are blocked by subscriptions. For example, if http://example.com/ is blocked by a subscription, you can unblock it by @*://example.com/*.

Highlighting rules

Match patterns or regular expressions preceded by @N (N=1,2,3,…) mean that the specified sites are highlighted.

For example, you can highlight GitHub by @1*://github.com/*.

highlight GitHub

By default, only @1 (blue) is available. To change or add highlighting colors, see the “Appearance” section in the options page.

Other search engines

This extension supports Bing, DuckDuckGo, Ecosia (partially) and Startpage.com. This feature is disabled by default and can be enabled in the options page.

other search engines

Bing

bing

DuckDuckGo

duckduckgo

Ecosia

For now, search scopes other than “Web” (e.g. “Images” and “Videos”) are not supported.

ecosia

Startpage.com

startpage

Sync

You can synchronize blacklists among devices using Google Drive or Dropbox.

NOTE: For technical reasons, sync is not available in Firefox for Android.

To turn on sync, click the “Turn on sync” button in the options page and select a cloud.

turn on sync

Follow the instructions on the dialog to authenticate.

authenticate

Once authentication succeeds, your blacklist will be regularly synchronized with the selected cloud.

Google Drive

If you use Firefox or its derivative, you will be required to permit access to https://www.googleapis.com.

The blacklist is saved in the application data folder on your Google Drive. It is hidden from you, although you can delete it in the settings page of Google Drive.

Dropbox

The blacklist is saved in the /Apps/uBlacklist/ folder on your Dropbox. The folder name may be different depending on your language.

Subscription

You can subscribe to public blacklists.

To add a subscription, click the “Add subscription” button and enter the name and URL. You will be required to permit access to the origin of the URL.

add subscription

You can show, update or remove a subscription.

manage subscription

Publish a subscription

To publish a blacklist as a subscription, place a blacklist file encoded in UTF-8 on a suitable HTTP(S) server, and publish the URL.

It is a good idea to host your subscription on GitHub. Make sure that you publish the raw URL (example).

raw url