init options

The second argument to entailInsights.init() changes how the SDK behaves on that page. Every option is optional — the snippet you copy already has the right defaults.

On this pageTurn features off on a pageTrackingRedirect testsCookies and storageSettings and loadingDifferent options on some pages

Updated November 28, 2026

Not set
Find it on the install page of your account. It stays in this browser and is never sent anywhere.

Pass options as an object after your site token:

JavaScript
entailInsights.init('YOUR_SITE_TOKEN', {
  disable_decide: false,
  autocapture: false, // example: don't track clicks on this page
});
Paste your site token at the top of the page to fill it in.

Options turn things off on this page only. They can't switch on a feature that's off for your website in CROforce. Setting popups: true doesn't show popups if none are live.

Turn features off on a page

Option

Default

What it does

experiments

true

Runs your A/B tests and feature flags. false keeps every visitor on the original page.

campaigns

true

Places your
campaigns
' widgets. false also turns off
redirect tests
, which run through campaigns.

widgets

true

Renders widgets you placed in your HTML and the
notification bar
.

popups

true

Shows your
popups
.

quizzes

true

Shows your
quizzes
.

lazyload

true

Loads widgets placed in your HTML only as they come near the screen. false loads them all at once.

Tracking

Option

Default

What it does

capture_pageview

true

Sends a page view on load and on every route change in a
single-page app
.

autocapture

true

Tracks clicks, form submissions and field changes. See
Automatically tracked events
.

rageclick

true

Records a rage click when someone clicks the same spot three times within a second each.

mask_all_text

false

Leaves out the text of what visitors click.

mask_all_element_attributes

false

Leaves out the attributes (like href or class) of what visitors click.

save_referrer

true

Records which site the visitor came from.

store_google

true

Records UTM parameters (utm_source, utm_medium, utm_campaign, utm_content, utm_term) and ad click IDs from the landing URL.

custom_campaign_params

[]

Extra URL parameters to record the same way, for example ['partner_id'].

custom_blocked_useragents

[]

Extra user-agent strings to treat as bots — for your own uptime monitor, say. Bots never get tests, campaigns or popups.

Redirect tests

Option

Default

What it does

hide_page

false

Hides the page while a redirect test decides whether to send the visitor elsewhere. Use it only on test pages.

hide_page_timeout_ms

1500

The longest the page stays hidden while deciding, in milliseconds.

redirect_rules

true

Decides redirect tests in the browser, which is faster than waiting for the server.

redirect_rules_cache_ttl_ms

600000 (10 minutes)

How long a returning visitor's saved copy of your redirect tests is used. Also how long a stopped test can still redirect someone who saw it.

When to use these: Redirect tests without flicker.

Cookies and storage

Option

Default

What it does

persistence

'localStorage+cookie'

Where visitor IDs are kept: 'localStorage+cookie', 'cookie', 'localStorage', 'sessionStorage' or 'memory'. With 'memory' every page load is a new visitor.

disable_persistence

false

Stores nothing in cookies or browser storage.

cookie_expiration

365

Days the en_ins cookie is kept.

cross_subdomain_cookie

true (false on *.herokuapp.com)

Sets the cookie on your root domain, so www.example.com and shop.example.com share one visitor. See
Visitor IDs
.

secure_cookie

true on HTTPS pages

Sends the cookie over HTTPS only.

Turning storage off changes your numbers. Without a stored visitor ID, a returning visitor counts as new, and a visitor can see a different test variant on each page.

Settings and loading

Option

Default

What it does

disable_decide

false

Keep it false, as in the snippet. true skips reading your website's settings, so features that depend on them don't start.

decide_cache_ttl_ms

86400000 (24 hours)

How long the browser reuses your website's settings. 0 reads them fresh on every page.

loaded

does nothing

A function called once the SDK is ready, with the SDK as its argument.

JavaScript
entailInsights.init('YOUR_SITE_TOKEN', {
  disable_decide: false,
  loaded: function (sdk) {
    // The SDK is ready: methods that the snippet doesn't queue work now.
    console.log('CROforce visitor', sdk.get_distinct_id());
  },
});
Paste your site token at the top of the page to fill it in.

Different options on some pages

Build the options from the URL. This keeps popups off the checkout and hides the page only on a redirect test page:

JavaScript
var path = location.pathname.replace(/\/$/, '');
entailInsights.init('YOUR_SITE_TOKEN', {
  disable_decide: false,
  popups: path.indexOf('/checkout') !== 0,
  hide_page: path === '/lp/get-started',
});
Paste your site token at the top of the page to fill it in.

Frequently asked questions

Do I need to change any options?

No. The snippet works as it is. Options are for special cases: a page where you don't want popups, a redirect test page, or a site that must not use cookies.

Can I set different options on different pages?

Yes. Options apply to the page where

init
runs, so you can build the options object from
location.pathname
.

Was this article helpful?

Try it on your own site

Add a popup, form or quiz to your site in a few minutes and see what it does for your conversions.