Google Consent Mode v2
What Consent Mode is
Google Consent Mode lets you tell Google tags whether a visitor has given consent for cookies and data use. Google tags then adjust their behavior based on that consent state.
ConsentBit sets the default consent state when a page loads. When the visitor makes or changes a choice in the banner, ConsentBit sends an update with the visitor's choice.
Google's own documentation: Consent mode overview and Set up consent mode on websites.
The consent settings
ConsentBit sets the following Consent Mode settings. The descriptions are Google's.
ConsentBit also sets these additional settings:
Default state: before the visitor makes a choice, every setting is denied except security_storage, which is granted.When the visitor accepts or saves preferences, ConsentBit sends a consent update, setting each value from the matching banner category.
Basic vs. Advanced Consent Mode
Google describes two ways to implement Consent Mode:
Which one to use is your decision. ConsentBit supports both.
Configure Advanced Consent Mode (ConsentBit default)
Option 1: ConsentBit script installed directly on your site
- Add the ConsentBit script as the first script in your <head>, above Google Analytics, Google Ads, or Google Tag Manager:
<script src="https://manager.consentbit.com/consentbit/YOUR_SCRIPT_ID/script.js"></script> - Leave your Google tag (gtag.js) or Google Tag Manager snippet as normal. Do not change its type to text/plain.
- Publish your site.
ConsentBit sets the denied default before your Google tags run, lets them load, and sends the update when the visitor chooses.
Option 2: Google Tag Manager (ConsentBit CMP template)
- In GTM, go to Tags → New → Tag Configuration and choose ConsentBit CMP from the Community Template Gallery.
- Paste your Script ID (Dashboard → Install).
- Optional: set default consent states by region in the Default consent state table.
- Set the trigger to Consent Initialization – All Pages.
- Leave your Google tags (GA4, Google Ads, Floodlight, Conversion Linker) on their normal triggers. Google tags have built-in consent checks and adjust automatically.
- Submit / Publish the container.
Configure Basic Consent Mode
In Basic mode, Google tags must not load until the visitor gives consent.
Option 1: ConsentBit script installed directly on your site
- Add the ConsentBit script as the first script in your <head> (same as above).
- Mark your Google tag so that ConsentBit holds it until consent. Change type to text/plain and add a category, on both the loader script and the inline config script:
<script type="text/plain" data-consentbit-category="analytics" async
src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXX"></script>
<script type="text/plain" data-consentbit-category="analytics">
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-XXXXXXX');
</script>
For Google Ads or Floodlight tags, use data-consentbit-category="marketing". See also Manual script tagging.
3. Publish your site.
ConsentBit loads these scripts only after the visitor grants the matching category, then sends the consent update.
Option 2: Google Tag Manager
- Add the ConsentBit CMP tag on Consent Initialization – All Pages (same as Advanced steps 1–4).
- For every Google tag in the container, open Advanced Settings → Consent Settings, choose Require additional consent for tag to fire, and add the matching settings:
- GA4 tags: analytics_storage
- Google Ads / Floodlight tags: ad_storage, ad_user_data, ad_personalization
- Add a Custom Event trigger with event name consentbit_consent_update to these tags, so they can fire after consent is given.
- Submit / Publish the container.
Check that it works
- Open your site in Google Tag Assistant (or GTM Preview), or add ?consentbit_debug=1 to the address (see Debug mode).
- In Tag Assistant, select the first event and open the Consent tab. You should see On-page Default with the denied values listed above.
- Click Accept in the ConsentBit banner. A Consent event should appear with On-page Update showing granted.
- Advanced: Google tags appear before you click Accept. Basic: no Google tags fire until after you click Accept.
If you use Google tag gateway, see Using ConsentBit with Google tag gateway.
To set up a banner that meets Google's requirements, see Create a banner that meets Google's requirements.

