Consent

Google Consent Mode v2

How allowedit sets Consent Mode v2 defaults per region before any Google tag loads, updates them on each choice, and when to pick advanced or basic mode.

Google Consent Mode v2 tells Google's tags what each visitor agreed to. allowedit sets it for you: a default before any tag loads, then an update when the visitor chooses. You don't add any Consent Mode code yourself.

It's on by default for every site, on every plan. You'll find the settings in your dashboard, under Banner, then Google Consent Mode.

The default, before any tag loads

The script is the first in your head, so it runs before Google Tag Manager or the Google tag. It sends a default command straight away, with the state each region needs:

RegionDefault
EU and EEA, the UK, Switzerland and QuebecEvery signal denied
US states with privacy lawsFollows your rule for that zone
Everywhere elseFollows your rule for that zone

The defaults are sent with Google's region codes (country codes like FR, plus CA-QC for Quebec and US-CA style codes for the US states), so they apply even before the visitor's zone is known. When a zone is set to Ask first (opt-in), its default is denied. When it runs with an opt-out or a notice, its default is granted, except for visitors sending Global Privacy Control, whose ad signals stay denied. See Region rules and GPC.

The update, when the visitor chooses

When the visitor accepts, rejects or saves their preferences, allowedit sends an update with their choice. It does the same on later page views, once the stored choice is read. The categories map to Google's signals like this:

allowedit categoryConsent Mode signals
Necessarysecurity_storage (always granted)
Preferencesfunctionality_storage, personalization_storage
Analyticsanalytics_storage
Marketingad_storage, ad_user_data, ad_personalization

ad_user_data and ad_personalization are the two signals Consent Mode v2 added. Google requires them for ads personalisation and remarketing with traffic from the EEA, so they're always set, never left out.

Advanced or basic mode

Advanced (the default)Basic
Before a choiceGoogle tags load in a denied stateGoogle tags don't load
What Google receivesCookieless pings, used for modellingNothing
Auto-blocking of Google tagsOff: the tags manage themselvesOn: held until their category is allowed

Advanced mode lets Google model conversions and visits from people who reject cookies. Basic mode sends nothing at all until consent. Both are valid; choose based on your own privacy stance and your lawyer's advice.

Two extra options

  • Ads data redaction (ads_data_redaction). While ad_storage is denied, ad click identifiers are removed from requests. On by default.
  • URL passthrough (url_passthrough). While cookies are denied, click information such as gclid is passed through page URLs instead, which helps measure conversions. Off by default, because it changes your URLs.

Check it works

With Tag Assistant: open Google's Tag Assistant, connect your site, and load a page in a fresh session. On the first event, the Consent tab should show the default (denied for an EU visitor). Choose an option on the banner, and the next event should show the update.

With GTM Preview: open Preview mode in Google Tag Manager. The Consent tab on each event shows the default and current state. You should also see an allowedit_consent event after each choice.

Test in a private window, so no earlier choice is stored.

The common mistake: two sets of defaults

Don't set Consent Mode defaults anywhere else. Old setups often have one of these:

  • A gtag('consent', 'default', ...) snippet in the theme, left from an earlier banner.
  • A Consent Mode template or "consent initialization" tag in Google Tag Manager.
  • A plugin or app with its own Consent Mode setting.

Two defaults fight each other, and the last one wins. Remove the others, so allowedit is the only thing setting defaults and updates.

The other common mistake is order: if the GTM snippet or the Google tag is above the allowedit script, Google's tags start before any default exists. Keep allowedit first.

Still stuck? Email support@allowedit.com with your site's address and what you see.