Skip to main content

Auto-enabled sites 🆕

Auto-enabled sites is a list of sites where tweak starts itself, so you do not have to press run or enable background request capture every time you open the page you work on all day.

It lives in more options (â‹®) > Settings > Auto-enabled sites, and it is available on every plan.

the auto-enabled sites section of the settings panel

info

This list takes precedence over any other action. If you stop tweak with the stop button and later come back to the same website, tweak is started again. To stop that, remove the site from the list.

What gets switched on​

Two switches decide what happens when a page matches, and they are independent:

SwitchWhat it does
Enable extensionApplies your active rules as soon as a matching page opens
Enable background request captureRecords the requests a matching page makes, so url autocompletion already has something to offer when you hop back on tweak to configure rules

Both are on by default, and adding your first site turns both back on. Turning one off is remembered: capture without interception is a great setup when you only want the autocomplete, and interception without capture is the classic one.

Both are re-applied on the next matching page load, and when you come back to a matching tab. Stopping tweak by hand still works, it just does not survive a reload of a site on the list.

When do I need this?​

It pays off when you move between browser tabs all day: an app on localhost, a staging environment, one internal tool. Instead of reaching for the extension icon on every tab, tweak is already running where you expect it to be.

Managing the list​

Type a site in the Web site field and press Add site. The list is unlimited. To drop one, click the x next to it.

Site specificity​

By default a site is matched as a plain substring of the page url, so how precise you are decides how wide the net is. When a substring is not expressive enough, an entry can be a regular expression instead.

tip

Adding https://tweak-extension.com/ enables tweak on every page of that site, which might be more than you want. Narrowing it to https://tweak-extension.com/docs restricts it to the documentation section. Targeted entries reduce conflicts between your different workflows.

Matching with a regular expression​

A substring cannot say "any of my preview environments" or "this host, but only its API routes". For that, press the .* button inside the Web site field before adding, and type a pattern instead of a site. It is the same modifier the url field of a rule carries, and it means the same thing here.

the regex modifier armed over a pattern, with a regex entry already in the list

A few things worth knowing:

  • The pattern is searched anywhere in the url, exactly like a substring. Anchor it with ^ when you want it to match from the start.
  • Matching is case sensitive, and the pattern takes no flags.
  • Added patterns are stored between slashes (/staging\.[a-z]+\.dev/) and carry a regex marker in the list, so you can tell at a glance how each entry is matched.

Some patterns to start from:

PatternMatches
^https?://localhost:\d+any port on localhost, over http or https
^https://[a-z-]+\.staging\.acme\.comevery preview environment under one staging domain
acme\.com/(api|graphql)only the API routes of a site, not the pages around them
tip

A pattern that matches too much is a wide net: .* on its own enables tweak on every page you open. Prefer the narrowest pattern that still covers your environments.

When the pattern does not compile​

tweak checks the pattern as you type. An invalid one is refused: the field turns red, says so, and the add button stays disabled, so a broken pattern never reaches your list.

the field refusing an invalid pattern

The .* button is what decides how the text is read, so the same characters can be perfectly valid as a plain site. Turn the modifier off and ^https://([a-z is just a substring that will never match, rather than an error.



Was this page helpful?

Need something else? Request a feature