Consent and privacy

Cookie consent and tracking go together: CROforce stops tracking a visitor who declines. Call entailInsights.opt_out_capturing() when a visitor declines tracking, and opt_in_capturing() when they accept. Opting out stops events and session recordings and deletes every CROforce cookie and storage entry.

On this pageThe three methods1. Find where your banner reports the choice2. Opt out on every page load3. Opt in when they acceptWhat keeps working for an opted-out visitor4. Check it worksWhat CROforce collects

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.

The three methods

JavaScript
entailInsights.opt_out_capturing();       // visitor declined
entailInsights.opt_in_capturing();        // visitor accepted
entailInsights.has_opted_out_capturing(); // true or false (once the SDK has loaded)

Method

What it does

opt_out_capturing()

Stops sending events, including the ones you send with
trackEvent
. Deletes every CROforce cookie and storage entry (they all start with en_) and stops writing new ones. Stops
session recording
and deletes what was already uploaded.

opt_in_capturing()

Turns tracking back on. On the same page, the visitor keeps the ID they had, so their visit isn't split in two.

has_opted_out_capturing()

Returns true while the visitor is opted out. Call it after the SDK has loaded — before that, the snippet's placeholder only queues the call.

The choice applies to the whole page, including any second instance you set up with a different name.

1. Find where your banner reports the choice

Every consent tool has a way to tell your code what the visitor chose — a callback, an event or a value you can read. Call the CROforce methods from there. Look for the "analytics" or "statistics" category.

2. Opt out on every page load

The opt-out isn't saved. It lasts until opt_in_capturing() or the next page load. Your consent tool keeps the visitor's choice, so check it and call opt_out_capturing() on every page.

The safest place is right after init in the snippet. The SDK reads a queued opt-out before it starts, so nothing is stored and no page view is sent:

HTML
<script>
  !function(t,e){ /* …your snippet… */ }(document,window.entailInsights||[]);
  entailInsights.init('YOUR_SITE_TOKEN', { disable_decide: false });

  // Replace with your consent tool's check.
  if (!visitorAcceptedAnalytics()) {
    entailInsights.opt_out_capturing();
  }
</script>
Paste your site token at the top of the page to fill it in.

If the choice is only known later, call it as soon as it is. The page view sent before that stays, but nothing after it is sent and the stored IDs are deleted.

3. Opt in when they accept

Generic

JavaScript
// Call from your banner's "accept" handler.
function onConsentAccepted() {
  entailInsights.opt_in_capturing();
}
function onConsentDeclined() {
  entailInsights.opt_out_capturing();
}

Google Consent Mode values

JavaScript
// If your banner exposes the analytics_storage decision:
function applyConsent(consent) {
  if (consent.analytics_storage === 'granted') {
    entailInsights.opt_in_capturing();
  } else {
    entailInsights.opt_out_capturing();
  }
}

Opt-in only (track nobody until they accept)

JavaScript
// Opt every visitor out on load, then opt in when they accept.
entailInsights.init('YOUR_SITE_TOKEN', { disable_decide: false });
if (!visitorAcceptedAnalytics()) {
  entailInsights.opt_out_capturing();
}
document.addEventListener('my-consent-accepted', function () {
  entailInsights.opt_in_capturing();
});
Paste your site token at the top of the page to fill it in.

visitorAcceptedAnalytics and my-consent-accepted stand for your consent tool's own check and event.

What keeps working for an opted-out visitor

  • Campaigns, widgets, popups, quizzes and A/B tests still show.
  • Nothing is stored, so popup frequency rules and test variants can't be remembered between pages.
  • No events are sent, so the visitor doesn't appear in your reports, test results or goals.

4. Check it works

  1. Open your site in a private window and decline tracking in your banner.
  2. Open DevTools › Application › Cookies: there should be no en_ins cookie, and no en_ entries in Local storage.
  3. In the Network tab, filter by t.entail-insights.com and click around. No new requests should appear.
  4. In the Console, run entailInsights.has_opted_out_capturing(). It should return true.

What CROforce collects

The cookie, what's stored, what session recordings capture and how long they're kept: Data, privacy and session replay.

Frequently asked questions

Does opting out remember the choice?

No. An opt-out lasts until the visitor opts in or leaves the page. Your consent tool remembers the choice, so call

opt_out_capturing()
on every page load for a visitor who declined.

Do popups and A/B tests still work for a visitor who opted out?

Yes. Campaigns, popups and tests keep showing, but nothing is stored in cookies or browser storage and no events are sent. Because nothing is stored, the visitor may see a different test variant on each page.

What happens to a session recording when a visitor opts out?

Recording stops right away, and CROforce asks the server to delete what was already uploaded from that recording.

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.