Basic Usage
URL filters limit rules to specific pages or domains. Leave the URL filter empty to apply a rule to all pages.
Simple matching:
example.com- Matches any URL containing “example.com”example.com/dashboard- Matches URLs with this pathexample.com/user/*- Matches any path starting with/user/
Wildcards
Use wildcards to match flexible patterns:
Asterisk (*) - Matches any sequence of characters:
*.example.com- Matches any subdomain (app.example.com, www.example.com)example.com/*/settings- Matches any path segment between/and/settingsexample.com/user/*/profile- Matches user profiles for any user ID
Question mark (?) - Matches a single character:
example.com/user?id=123- Matches URLs with a single character beforeid=123example.com/page?- Matches URLs ending withpage?followed by one character
Multiple Domains (OR Operator)
Use brace expansion {a,b,c} to match multiple options:
Multiple domains:
{example.com,test.com,demo.com}- Matches any of these three domains{app.example.com,staging.example.com}- Matches specific subdomains
Multiple paths:
example.com/{dashboard,settings,profile}- Matches any of these three pathsexample.com/user/{123,456,789}- Matches specific user IDs
Combined patterns:
{example.com,demo.com}/dashboard- Matches dashboard on either domainexample.com/{en,fr,de}/*- Matches localized pages for English, French, or German
Advanced Examples
Match all pages on a domain except specific paths:
- Use multiple rules with different filters, or combine with custom CSS rules
Match staging and production environments:
{staging.example.com,app.example.com}- Applies to both environments
Match specific query parameters:
example.com?mode=demo- Matches URLs with this query parameterexample.com/*?user=*- Matches any path with a user query parameter
Match multiple page types:
example.com/{product,service,about}/*- Matches product, service, and about pages
How It Works
URL filters use substring matching by default. When you include wildcards (*, ?) or brace expansion ({...}), the filter is converted to a regular expression for pattern matching.
Empty filter: Rule applies to all pages Simple text: Matches if the URL contains the text anywhere Glob patterns: Converted to regex for pattern matching
Tips
- URL filters are case-sensitive
- Matching is done on the full URL (including protocol, domain, path, and query)
- Use specific filters to avoid unintended matches (e.g.,
example.com/dashboardinstead of justdashboard) - Test your filters by checking if rules appear in the rules list when on matching pages
- Combine multiple rules with different filters for complex scenarios