Skip to content

Tracking and Consent

AutoROICalc can count interactions or connect them to marketing sources. Choose the data you need, then connect the appropriate tracking mode to your site's consent process.

Anonymous event counting counts actions without browser storage or visitor identifiers. Attribution tracking can use browser storage and campaign sources. No runtime consent gate skips a consent check; it does not turn attribution tracking into anonymous counting.

This guide covers the JavaScript/npm module version 3 and the current WordPress plugins. Older versions can behave differently.

Your site's consent manager displays the banner, explains purposes, remembers visitor choices, and passes those choices to AutoROICalc. The tracking module does not provide a consent banner or decide whether your use requires consent.

In the default consent-required setup, attribution waits for a grant. A missing signal is not permission. Pass the current choices after the tracking runtime is ready on every page load, and update them when the visitor changes their choice.

The site owner remains responsible for the purposes, disclosures, consent process, and data sent. Selecting a bypass setting does not establish consent or another legal basis.

Choose the tracking you need

Goal JavaScript/npm module WordPress plugins
Count clicks, hover, or other interactions without attribution Call sendAnonymousEvent() from your interaction handler Event Tracking: choose Tracking mode → Anonymous event counting on supported targets
Connect events to campaign sources Grant the appropriate consent, then use attribution methods Keep Consent mode → Require explicit browser consent signal and choose Analytics or Marketing for the event
Let the site's own process control when tracking may run Your integration controls when it supplies consent signals No runtime consent gate skips an event's check; Consent is managed by the site bypasses the plugin's internal checks globally

The WordPress bypass settings are separate from the JavaScript module's consent API. They do not change which data an event can contain.

Anonymous event counting

Use this when you only need answers such as “How many times was the pricing button clicked?”

The anonymous path uses no cookies, local storage, session storage, visitor identifiers, or captured attribution. Use static types and counter names, such as button_click and pricing_signup. Never put an email address, customer ID, or other personal data in those labels.

Each accepted interaction adds a value of 1. Repeated interactions count again, so the result measures events rather than unique people. Anonymous events remain anonymous-mode events after a visitor grants consent; consent does not add attribution to them.

The JavaScript method sends an event when you call it; attach it to the interaction you want to measure. WordPress Event Tracking supports anonymous click, hover, and visibility counters on supported page elements. WooCommerce journey tracking has no anonymous counting mode.

Other scripts on the page may still use storage. Web servers also receive connection metadata, so review access logs and retention alongside the counter configuration.

Attribution tracking

Use this when you need to connect an action to a campaign, referrer, or source / medium. Depending on the integration, this can use local storage, session storage, and source cookies, and include configured event details.

The standalone JavaScript module accepts Analytics and Marketing signals. Either grant enables its shared attribution methods; these methods do not have separate per-event category gates. Choose the signal according to the purpose explained to visitors.

The WordPress plugins additionally let you choose an event's consent category. In consent-required mode, an Analytics event waits for Analytics and a Marketing event waits for Marketing.

This option allows a WordPress event to run without the plugin checking that event's consent category. It can still include attribution and event details, and normal tracking can still use browser storage. Other checks can still apply: the option does not grant Analytics consent to WooCommerce checkout attribution.

Use it only as part of a deliberate site-managed setup. For example, the site may control whether the tracking code runs through a separate consent integration. If that outside control is absent, the event may run before the visitor has agreed.

After the runtime is ready, map the visitor's actual choices to both categories:

// Example: the visitor accepted Analytics and declined Marketing.
window.AutoRoiCalc.setConsent({
  analytics: true,
  marketing: false
});

// Run when the visitor withdraws both categories.
window.AutoRoiCalc.setConsent({
  analytics: false,
  marketing: false
});

For npm, use your AutoRoiCalc instance in place of window.AutoRoiCalc. These are callbacks to connect to your consent manager, not two calls to run consecutively during setup. Send the full current choice so an old grant is not accidentally left enabled. The standalone module keeps its consent state in memory; supply it again on each page load.

The WordPress plugins also accept an autoroicalc:consent browser event with the same values in detail. Follow the individual plugin guides for storage and cleanup behavior. Withdrawing consent blocks subsequent consent-gated tracking; it does not delete records already delivered. Anonymous counting follows its separate mode, and explicit bypass settings continue to bypass their checks.

WooCommerce checkout is separate

Journey events, captured checkout attribution, and paid-order/refund reporting are separate flows.

In consent-required mode, attaching captured checkout sources requires Analytics consent, even if journey events use Marketing or No runtime consent gate. Withdrawing Analytics removes the checkout source cookie; checkout updates without Analytics clear previously attached captured attribution. Administrator-defined fixed sources are separate from captured visitor sources.

Consent is managed by the site explicitly bypasses the internal consent checks. Paid-order and refund reporting are server-side flows and are not switched off by the browser journey consent category. See the WooCommerce guide for the data those records contain.

Consent connects the visitor's choice to what the website actually does. Collecting no names does not, by itself, answer whether consent is needed. In Europe, rules on storing or accessing information on a device can apply beyond cookies, and personal-data processing has its own requirements. See the European Commission's cookie guidance and the EDPB's guidance on the technical scope of ePrivacy Article 5(3).

Anonymous counting reduces the data collected; it is not a promise that every deployment is exempt from consent. Assess your purpose, implementation, logging, and applicable local rules before deciding when collection may run.

Check your setup

  1. Start a fresh visitor session with no saved choice. Confirm gated events and attribution wait.
  2. Grant only Analytics, then only Marketing. Confirm events follow the intended categories.
  3. Withdraw consent. Confirm later gated events stop, including after reloading the page.
  4. If using anonymous counters, inspect requests and storage to confirm the anonymous path is used and labels contain no personal data.
  5. For WooCommerce, test checkout attribution separately from journey events and order reporting.

Implementation guides