Tracker configuration
You can tweak how the tracker behaves by adding data attributes to the script tag. Here’s what each one does.
data-host-url
Normally, data goes to the same origin as the script. Use this to point it somewhere else (e.g. a separate analytics endpoint).
<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-host-url="https://stats.yoursite.com"></script>data-auto-track
Pageviews and link events are tracked automatically by default. Set "false" to switch that off and send everything yourself with the tracker functions.
<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-auto-track="false"></script>data-domains
Restrict the tracker to certain domains. Use a comma-separated list; each value is checked against window.location.hostname. Watch out for www vs non-www. Handy for keeping dev or staging from polluting production data.
<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-domains="yoursite.com,www.yoursite.com"></script>data-tag
Label all events from this script with a tag. You can then filter or segment by that tag in the dashboard.
<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-tag="campaign-a"></script>data-exclude-search
Set to "true" and the URL’s query string (?foo=bar) won’t be stored.
<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-exclude-search="true"></script>data-exclude-hash
Set to "true" to strip the hash (#section) from the URL before sending.
<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-exclude-hash="true"></script>data-do-not-track
When "true", the tracker honors the browser’s Do Not Track setting and won’t send data for those users.
<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-do-not-track="true"></script>data-before-send
Name of a function that runs right before each send. It gets type and payload. Return the (possibly modified) payload to send, or return false / null to skip sending that request.
function beforeSendHandler(type, payload) {
if (checkPayload(payload)) return payload;
return false;
}<script defer src="https://your-cdn.com/intrily.js" data-website-id="your-website-id" data-before-send="beforeSendHandler"></script>