Skip to content
  1. Home
  2. How KO works
  3. Cookies and consent
How KO works

Cookies and consent

The KO counter does not ask the visitor and does not read your banner: your site's code passes the decision to it. When consent is denied, it writes nothing to the device and sends no visit data. When consent is withdrawn, it deletes what it has already stored.

In short

  • Your banner decides The counter carries out the decision your site's code passes to it.
  • Denied means no storage and no sending No cookies, no storage keys, no visit data.
  • Withdrawal deletes its records The counter removes its cookies and keys at once.
  • Pixels are the banner's job KO consent does not block advertising pixels.

Your site’s banner makes the decision

The KO counter does not show its own window and does not read anyone else’s. It does not look at the consent platform’s cookies, at dataLayer or at Google Consent Mode. Your site’s code passes the visitor’s choice to it with one call.

Decides

Your site's banner

asks the visitor about all tags on the site at once

Follow the decision

KO countercall from your site
Advertising pixelsblocked by the banner
Chat, maps, other tagsblocked by the banner
The banner is the one place where the visitor decides. The KO counter is one of the tags that follow that decision

A banner asks the visitor about all tags on the site at once: analytics, ads, chat. The counter is one of these tags. So it follows the same decision as the others and does not ask its own question.

Until your site passes anything, the counter assumes there are no restrictions and works as usual.

The call accepts the short keys analytics and ads, and also the names from Google Consent Mode. If the counter does not recognise a value, it treats it as “not set”, not as a denial, and does not change its state in either direction.

You set how the counter reacts to the banner

Your site’s code decides how the counter responds to each banner button, not KO. You do not need any setting on our side for this, and you do not wait for us. You can combine these options:

  • Load the counter only after consent. Until the visitor decides, not a single request goes to KO.
  • Declare a denial before loading. The counter is on the page but stays silent until your site passes consent.
  • Pass the decision from a banner button. You choose which answer means consent and which means denial, for example “Necessary only” or a closed window.
  • Turn analytics fully on. Pass analytics: 'granted' or do not pass a denial at all. Then the counter works with no restrictions: it sets cookies, sends visits and events, and substitutes phone numbers.

The counter carries out any of these options. Which one is allowed for your visitors is for your lawyer to decide.

Storage on the device

cookies, localStorage, sessionStorage

nothing is written

Visits and events

visit data, events, phone number substitution

nothing is sent

Form submission

the person sent it themselves

goes through

not linked to a visit

Advertising pixels

goals sent to pixels on the page

KO consent does not block them

the banner blocks them

What happens when the visitor denies analytics

A denial for analytics stops two things:

  • storage — cookies, localStorage and sessionStorage;
  • sending — visit data, events and phone number substitution.

The counter can stay on the page, but it writes nothing and sends nothing. A simpler option is not to load it until the person allows analytics: then there is not a single request to KO before the decision.

A form submission still goes through when consent is denied: the person sent it themselves. It will not be linked to a visit.

A person can change their mind after the counter has started. When consent is withdrawn, the counter at once:

  • stops — it sends no new visits or events;
  • deletes its cookies: _ko_client_id, _ko_touch_id, _ko_touch_id__session, _ko_session_id, _ko_visit_id, _ko_uid, _ko_tracks_email_id;
  • clears its keys in localStorage and sessionStorage — everything that starts with _ko_ and ko..

The counter does not touch cookies of other systems: the banner or the tag that set them removes them.

Substituted phone numbers stay on the page until it reloads. The counter no longer updates them, but it does not put the original numbers back either.

What the counter does not do

  • It does not block advertising pixels. The counter stores the ads key, but nothing depends on it today: goals go to the pixels on the page regardless of consent. Your banner blocks the pixels, the same way it blocks other tags.
  • It does not show its own banner.
  • It does not store the visitor’s choice. The banner remembers it.
  • It does not recognise the visitor by a browser fingerprint — neither before a denial nor after it.

Where the instructions are

How to pass the banner’s decision to the counter, set a denial before it loads and check it all in the browser — see the help article The cookie banner and the KO counter.

What kind of consent your site needs, and in what form, is for your lawyer to decide. The counter carries out the decision it is given.

Summary

  • Your site’s banner decides about consent, and the counter carries out that decision.
  • Your site’s code sets how the counter reacts to the banner, up to full analytics with no restrictions.
  • A denial stops storage on the device and sending of visit data. A withdrawal deletes the counter’s cookies and keys.
  • A form submission always goes through, but it is not linked to a visit.
  • Block advertising pixels with your banner: KO consent does not block them.

Updated

Demo

Imagine your project is already in KO

The demo is the project of a made-up company. Its ads, website and CRM are already connected. Reports, decisions and data checks work on its numbers just as they would on yours.

See it live

No sign-up, no payment