Configuration
Exclude paths
Skip admin pages, previews, and anything else you do not want counted.
Use data-exclude on the script tag to skip paths. Excluded paths send no
request at all.
<script
defer
data-domain="example.com"
data-exclude="/admin/*, /preview/*, /draft"
src="https://sift.agentonboard.xyz/js/sift.js"
></script>Pattern rules
- Patterns are separated by commas.
- Whitespace around each pattern is trimmed.
- A pattern without
*must match the pathname exactly. *matches any sequence of characters, including/.- Matching happens in the browser, against
location.pathname. - Matching is case-sensitive.
| Pattern | Matches | Does not match |
|---|---|---|
/draft | /draft | /draft/1, /drafts |
/admin/* | /admin/, /admin/users, /admin/users/1 | /admin, /administrator |
/preview/* | /preview/post-1 | /preview |
* expands to zero or more characters, but everything else in the pattern is
literal — including the slash. /admin/* needs the /admin/ prefix, so it does
not match /admin on its own. List both when you want both:
data-exclude="/admin, /admin/*"Query strings are ignored
Exclusion tests the pathname, not the full URL. /search?q=secret is tested as
/search. Exclude /search to skip all of it.
What exclusion does not do
- It does not stop the script from loading. Only the pageview is skipped.
- It does not apply retroactively. Pageviews already stored stay stored.
- It cannot exclude by referrer, country, or device — only by path.
Common setups
<!-- skip the whole admin area and staging previews -->
data-exclude="/admin, /admin/*, /preview/*"
<!-- skip a checkout flow -->
data-exclude="/cart, /checkout, /checkout/*"
<!-- skip a single landing page used for ad testing -->
data-exclude="/lp/test-a"