Consent and Cookies
What the Tapper script does with and without consent, the two ways to tell it your visitor's choice, and how to verify it on your site.
Tapper runs from a single script on your website. This page covers what that script does with and without consent, how to tell it about a visitor's choice, and what you need to register in your consent management platform (CMP).
This page is documentation, not legal advice. How you classify Tapper and what consent you collect remain your decisions, together with your own advisers.
The uppercase call format below matters. The exact "GRANTED" /
"DENIED" uppercase format documented below is in the script build served
since 2026-09-04 09:23 UTC; a site that still holds a cached copy of the
previous build picks up the new one within an hour, and until then that
copy silently ignores the uppercase spelling.
Your Integration Does Not Change
Consent handling lives inside the script, not in your integration:
- The same Monitoring Script and Conversion Script tags stay exactly where they are.
- The snippet still calls
tapper.init(pk)with your public key. - You still report conversions with
window.tapper.push(...), unchanged.
One script, one integration — what it is allowed to do underneath changes with consent.
What the Script Does, With and Without Consent
The script runs in one of two modes per visitor, chosen automatically, based on the policy you set on the protection-script page (Website monitoring tab).
| With consent (cookie mode) | Without consent (cookieless mode) | |
|---|---|---|
| Device storage | Writes the tsid cookie plus the local/session storage entries described below | Writes nothing to the device — no cookie, no local storage, no session storage |
| Cross-session identity | Yes — the same visitor is recognised across page views and return visits | No — every page load starts fresh |
| Fraud and security signals | Captured | Partially captured — page views (the landing page, since the click id must be in the URL), events, clicks, and the tab record are still captured, and passive server-side/wire signals (IP, user agent, headers, server-side JA4) ride along on every request regardless of mode. What does not run: the active browser-fingerprint probe fan-out (canvas, WebGL, audio, WebRTC, and the rest — skipped entirely, never subsetted), the client-side network fingerprint read (JA4/JA4H), and recovery of Google's _gcl_aw/_gcl_dc click-id cookies |
| Conversions | Recorded and attributed to the click that brought the visitor in, for as long as that identity is remembered | Still sent with its order value, currency, order id and click id — nothing is stripped — and labelled captured_cookieless, but nothing about it is stored either |
| Ad-platform audience scripts served through Tapper | Injected | Not injected |
Cookieless mode costs storage, not the conversion itself. Tapper does not remove order value, currency, or the click id from a cookieless conversion — those still ride along, the same as in cookie mode. What's missing is durability: with nothing written to the device, the click id only survives for as long as it is present on the page — in practice the landing page view, or a later page you carry it forward on yourself during that same visit. A visitor who leaves and returns with no click id in the URL is not recognised, and the next conversion has nothing to attribute to.
What the Script Stores on a Visitor's Device (Cookie Mode Only)
| Name | Type | Purpose | Duration |
|---|---|---|---|
tsid | Cookie | Holds the Tapper visitor identifier, together with the ad click id and any UTM parameters from the click that brought the visitor to your site. Used to attribute conversions to the correct click and to run fraud analysis. | 1 year. |
_tapper_lksd | Local storage | Records which ad click ids have already been seen in this browser, so the same click is not counted twice. | Until the visitor clears their browser storage. |
tbsid | Session storage | Identifies the current browser tab, so activity in one tab is not mixed with another. | Until the tab is closed. |
_tapper_mode | Session storage | Persists the resolved cookie-mode decision for the rest of the current visit, so later page views in the same tab do not have to re-derive it. | Until the tab is closed. |
cookietest | Cookie | Not ours — set and deleted by our fingerprinting dependency (FingerprintJS) as part of its device-signal checks. It rides on the same device budget as the entries above and is subject to the same gate. | Deleted immediately after it is set. |
None of these are written in cookieless mode. If a visitor grants consent mid-visit, the script starts writing them and carries the same visitor identity forward, so the click that brought them in is not lost.
The script only does anything at all when it can identify an ad click —
from a click id in the page URL, from a value it stored earlier, or from a
Google click cookie already on the page. If it cannot find one, it removes
its own cookie and stops. A visitor who never arrives from an ad does not
get a tsid.
Attributes of the tsid Cookie
Register these in your CMP alongside the entry above:
| Attribute | Value |
|---|---|
| First-party | Yes — set by JavaScript via document.cookie on your own site. |
| Domain | The registrable domain of your site, for example .example.com. |
| Path | / |
| Flags | Secure, SameSite=None, Partitioned |
| Lifetime | 1 year from the moment it is first written. It is not extended on later visits while its value is unchanged. |
Cookies Tapper Reads but Does Not Set
If they are already present, the script reads Google's own _gcl_aw and _gcl_dc cookies to recover the click id. These are set by your Google tags, not by Tapper, and you declare them under Google in your CMP as you already do.
Two Ways to Tell Tapper About Consent
Tapper reads consent from two places. Door 1 — your direct call — is the more deliberate signal. Once given, it decides the mode regardless of what Google Consent Mode reported before it, and a grant reported through Door 2 afterward can never override a decision Door 1 already made. There is one exception to that, covered in the warning below.
Door 1 — call tapper.consent() directly
If your own CMP, cookie banner, or in-house consent flow knows the outcome, tell the script directly:
window.tapper.consent("GRANTED");
window.tapper.consent("DENIED");These are the only two values accepted, and they are case-sensitive —
exactly "GRANTED" or "DENIED", uppercase. "granted", "Denied", or
any other string is ignored; there is no lowercase alias. Call it as many
times as you like — a repeated call with the same decision is a no-op.
Door 2 — Google Consent Mode
If you already run Google Consent Mode through gtag or a CMP that
publishes it, you do not need to write any code for this door. Tapper
reads the ad_storage signal your CMP pushes to gtag, and only acts on
an explicit update — never on a configured default and never on an
implicit value. A default is your site's configuration, not the
visitor's answer, so it never gates.
One exception: a real denial always applies, even against a Door 1 grant. If Door 1 has already granted and Google Consent Mode later reports an actual change to Reject — not a repeat of what it already reported — that denial overrides the earlier grant and the visitor moves back to cookieless mode. Withdrawing consent is a right no door can be blocked from exercising, so a change to DENIED always applies, whichever door it comes through. A change to GRANTED does not carry the same power — it only applies when it comes from the same or a more deliberate door than whatever decided last, so a grant reported through Door 2 can never reopen a decision Door 1 already made. A door repeating the answer it already gave changes nothing either way.
The Google Ads Upload Stamp
Separately from which door decided our mode, Tapper reads ad_user_data and
ad_personalization from Google Consent Mode and stamps them on the
conversions we upload to Google Ads — this is the consent status Google
requires on every upload for EEA and UK visitors. If we hold no consent
signal for a visitor, that field is uploaded as unspecified — unless we have
confirmed the visitor is outside the EEA and UK, in which case it is
uploaded as granted. That confirmed-non-EEA/UK case is a statement about
jurisdiction, not about a choice the visitor made.
Your Script's Consent Policy
The ladder is choice, then policy, then region: an explicit choice through either door always wins; below that, your script's policy decides what a visitor with no choice yet gets; region only matters inside the Region-based policy. A DENIED always applies regardless of policy — no policy can override a real denial.
You set the policy yourself, on the protection-script page, on the Website monitoring tab (at the top) — workspace owners and admins can change it. There are three:
| Policy | With no consent signal yet |
|---|---|
| Region-based | Cookie mode outside the EEA/UK, cookieless mode inside it — see below |
| Consent first | Cookieless mode everywhere, until a visitor explicitly grants |
| Cookie first | Cookie mode everywhere, until a visitor explicitly denies |
Your script's current policy is shown on the protection-script page, on the Website monitoring tab (at the top). This page does not state which policy applies to you — it's a setting you control, not a fixed default.
EEA/UK and Elsewhere Under the Region-Based Policy
- A denial from either door applies everywhere in the world, not only in the EEA and UK.
- With the Region-based policy active and no consent signal at all:
- Visitors outside the EEA and UK get cookie mode — full attribution.
- Visitors inside the EEA and UK get cookieless mode — fraud protection only — until they grant consent.
- An unresolved location is treated the same as EEA/UK for this decision, because that is the only direction that cannot produce a claim we do not hold.
- The Consent first and Cookie first policies don't vary by region — see "Your Script's Consent Policy" above.
Example: Firing the Hook from Google Tag Manager
If your CMP does not publish Google Consent Mode and you want to wire Door 1 through GTM instead of your CMP's own script:
<!-- Custom HTML tag, triggered on your CMP's own "consent updated" event -->
<script>
(function () {
if (typeof window.tapper === "undefined") return;
// Replace this with however your CMP exposes the visitor's choice
var granted = yourCmp.getConsentState("advertising") === true;
window.tapper.consent(granted ? "GRANTED" : "DENIED");
})();
</script>Fire this tag on your CMP's consent-update event, not on page load — the same rule that applies to Google Consent Mode applies here: only an actual choice should reach tapper.consent(), not a configured default.
If you already run Google Consent Mode correctly, Door 2 needs no code at all — the script reads it directly off gtag.
Verifying It's Working
Use this checklist to confirm cookieless mode is doing what you expect for your site.
- Open your browser's DevTools Network tab and reload the page.
- Find the request the monitoring script makes to
users.ping(orusers.registerTabon a returning visit) and inspect its response JSON for three fields:is_eea_or_uk(whether the visitor resolved as EEA/UK),consent_regime(your script's policy — one ofGEO,CONSENT_FIRST,COOKIE_FIRST), andconsent_gate(reads"GATE_ON"— the gate is live). - With consent granted, the response carries the visitor's identifiers and the browser sets the
tsidcookie plus_tapper_lksd(local storage) andtbsid(session storage) — check the Application → Cookies/Local Storage/Session Storage panels for them. - With consent denied or unresolved in the EEA/UK, none of
tsid,_tapper_lksd, ortbsidappear after the request — this is the confirmation that cookieless mode is active. - If you call
tapper.consent("GRANTED")from the console after a denial, reload the network trace and confirm the cookie and storage entries now appear.
Declaring Tapper in Your CMP
Add the entries above to your cookie inventory so your banner reflects what actually runs on your site.
Fraud and security signals are commonly classified as necessary or security in CMP inventories, because they exist to protect the site and the advertiser rather than to profile the visitor. Attribution and measurement storage is commonly classified as marketing or statistics.
Tapper cannot make that classification for you. The tsid cookie carries
both a fraud-analysis identifier and click attribution data in a single
entry, so where it belongs in your inventory depends on your own assessment
and your advisers. Classify it, then make sure your banner matches.
Withdrawing Consent
When a visitor withdraws consent — through either door — the script:
- Deletes the
tsidcookie and the local/session storage entries above. - Stops attribution for that visitor going forward.
- Keeps fraud protection running.
- Applies the withdrawal immediately. Door 2 withdrawals are also recorded on our consent wire today; Door 1 withdrawals are queued to be recorded the same way once that reporting path ships on our side — either way, the mode change itself is not delayed by that.
Nothing on this page requires a change to your tags to keep working. If a visitor changes their mind mid-visit, through either door, the script picks it up and switches modes without a page reload.