[Go to site: main page, start]

How to set up Google
Tag Manager

Follow this setup if you are using Google Tag Manager to manage your third-party scripts.

Watch Tutorial

Follow this step-by-step guide to set up Google Tag Manager:

Note: Consent Pro is the standalone successor to the Cookie Consent solution previously included in Finsweet Components. You may still encounter mentions of “Cookie Consent” or “Components” in the screenshots of this documentation, but they remain accurate and applicable for following the tutorial.

1

Remove the <noscript> tag from Google Tag Manager

First, go to 'Site Settings' > 'Custom Code' and remove the Google Tag Manager <noscript> tag from the footer code.

Website backend showing custom code editor with Google Tag Manager noscript code snippet in the footer code section.
2

Download the Finsweet Google Tag Manager template for Consent Mode

Click the button below to download the template required for setting up Google Tag Manager:

Download Template
3

Import the Finsweet Google Tag Manager template

Go to your Google Tag Manager account > 'Templates' and click on 'New' in the tag templates section.

Google Tag Manager interface showing no tag or variable templates with green arrows pointing to New and Templates buttons.

Click on the three dots in the top right corner and select 'Import'.

Template Editor interface with Import option highlighted in dropdown menu under three-dot icon.

Select the downloaded Finsweet Consent Pro template and click 'Open'.

Mac Finder window showing Downloads folder with file 'Finsweet Consent Pro - GTM Template.tpl' selected.

Click on 'Agree to Community Template Gallery Terms of Service' and 'Save'.

Template Editor screen with a cookie consent GTM template and a Save button in top right corner.
4

Create a tag for Consent Mode Initialization

Go to 'Tags' and click 'New'.

Google Tag Manager interface showing no tags and arrows pointing to the Tags menu and New button.

Name it 'Consent Mode Init' and click on 'Tag Configuration'.

Google Tag Manager interface showing Tag Configuration and Triggering options with placeholders.

Choose 'Finsweet Consent Pro - GTM Template'.

Google Tag Manager interface showing tag type choices including Finsweet Consent Pro GTM template highlighted.

Select the 'Mode': Opt-in or Opt-out.

Dropdown menu in tag configuration with consent mode options OPT IN, OPT OUT, and variables visible.

* Ensure it matches the 'Mode' you selected in the app.

Consent Pro interface shows Opt In mode selected for GDPR cookie compliance with detailed explanations.

Click on 'Triggering'.

Google Tag Manager interface showing Consent Mode Init tag with no triggering event selected.

Select 'Consent Initialization - All Pages'.

Screen showing trigger options with Consent Initialization - All Pages highlighted in a tag manager interface.

And 'Save'.

Google Tag Manager interface showing Consent Mode Init tag configuration and a highlighted Save button.

If you want more control over when to fire your tags, click on '+' button.

Google Tag Manager interface showing custom event trigger configuration with conditions and add condition button.

And select the conditions you want. They can be triggered when a user accesses a specific page or when another custom event occurs:

Google Tag Manager trigger configuration with custom event and dropdown for selecting variables.
5

Create a trigger for Essential Cookies

Go to 'Triggers' and click 'New'.

Tag Manager interface showing the Triggers tab with no triggers and a highlighted New button.

Name it 'Essential Cookies' and click on 'Trigger Configuration'.

Google Tag Manager interface showing Trigger Configuration with options to choose a trigger type.

Choose 'Custom Event'.

Menu for choosing trigger type in a UI, highlighting 'Custom Event' option under Other category.

Fill 'Event Name' with 'essential-activated', select 'Event', choose 'equals', and enter 'essential-activated'.

Screenshot of Google Tag Manager trigger setup for custom event named essential-activated with conditions.

and 'Save'.

Google Tag Manager screen showing trigger config for custom event 'essential-activated' and Save button.

If you want more control over when to fire your tags, click on '+' button.

Google Tag Manager interface showing custom event trigger configuration with conditions and add condition button.

And select the conditions you want. They can be triggered when a user accesses a specific page or when another custom event occurs:

Google Tag Manager trigger configuration with custom event and dropdown for selecting variables.
6

Create a trigger for Marketing Cookies

Go to 'Triggers' and click 'New'.

Tag Manager interface showing the Triggers tab with no triggers and a highlighted New button.

Name it 'Marketing Cookies' and click on 'Trigger Configuration'.

Google Tag Manager interface showing new trigger setup for Marketing Cookies with arrow icons.

Choose 'Custom Event'.

Menu for choosing trigger type in a UI, highlighting 'Custom Event' option under Other category.

Fill 'Event Name' with 'marketing-activated', select 'Event', choose 'equals', and enter 'marketing-activated'.

Google Tag Manager trigger config showing custom event named marketing-activated with condition equals marketing-activated.

and 'Save'.

Google Tag Manager trigger configuration for custom event marketing-activated with Save button top right.

If you want more control over when to fire your tags, click on '+' button.

Google Tag Manager interface showing custom event trigger configuration with conditions and add condition button.

And select the conditions you want. They can be triggered when a user accesses a specific page or when another custom event occurs:

Google Tag Manager trigger configuration with custom event and dropdown for selecting variables.
7

Create a trigger for Personalization Cookies

Go to 'Triggers' and click 'New'.

Tag Manager interface showing the Triggers tab with no triggers and a highlighted New button.

Name it 'Personalization Cookies' and click on 'Trigger Configuration'.

Google Tag Manager interface showing trigger setup with 'Personalization Cookies' label and two green arrows.

Choose 'Custom Event'.

Menu for choosing trigger type in a UI, highlighting 'Custom Event' option under Other category.

Fill 'Event Name' with 'personalization-activated', select 'Event', choose 'equals', and enter 'personalization-activated'.

Google Tag Manager trigger configuration for custom event named personalization-activated with matching condition.

and 'Save'.

Google Tag Manager trigger configuration for custom event named personalization-activated with Save button highlighted.

If you want more control over when to fire your tags, click on '+' button.

Google Tag Manager interface showing custom event trigger configuration with conditions and add condition button.

And select the conditions you want. They can be triggered when a user accesses a specific page or when another custom event occurs:

Google Tag Manager trigger configuration with custom event and dropdown for selecting variables.
8

Create a trigger for Analytics Cookies

Go to 'Triggers' and click 'New'.

Tag Manager interface showing the Triggers tab with no triggers and a highlighted New button.

Name it 'Analytics Cookies' and click on 'Trigger Configuration'.

Google Tag Manager workspace with a popup titled Analytics Cookies for trigger configuration.

Choose 'Custom Event'.

Menu for choosing trigger type in a UI, highlighting 'Custom Event' option under Other category.

Fill 'Event Name' with 'analytics-activated', select 'Event', choose 'equals', and enter 'analytics-activated'.

Google Tag Manager trigger setup for custom event 'analytics-activated' with condition to fire on that event.

and 'Save'.

Google Tag Manager screen showing custom event trigger named analytics-activated with Save button highlighted.

If you want more control over when to fire your tags, click on '+' button.

Google Tag Manager interface showing custom event trigger configuration with conditions and add condition button.

And select the conditions you want. They can be triggered when a user accesses a specific page or when another custom event occurs:

Google Tag Manager trigger configuration with custom event and dropdown for selecting variables.
9

Update how the scripts are triggered for Cookie compliance

Select the script that should be prevented from loading. This script will only load when the user consents to a specific category.

For this example, we are going to use the 'Facebook Pixel' tag:

Google Tag Manager interface showing Tags section with Facebook Pixel tag highlighted and a green arrow.

Click on 'Edit icon'.

Google Tag Manager interface showing Facebook Pixel custom HTML code and triggering settings for all pages.

Remove the current trigger.

Google Tag Manager screen showing Facebook Pixel code snippet with triggering set to fire on all pages.

Click on 'Triggering'.

Google Tag Manager screen showing Facebook Pixel code snippet with triggering set to fire on all pages.

Choose the new trigger.
For Facebook Pixel, for example, we can choose 'Marketing Cookies'.

Google Tag Manager trigger menu with Marketing Cookies custom event highlighted and a green arrow pointing to it.

That means the Facebook Pixel script will only load when the user consents to the 'Marketing' category or clicks on 'Accept All'.

Consent preferences window showing marketing category checked, with options to reject, accept, or save preferences.

You can select the trigger you think fits best for each script.

10

Add additional consent checks for each tag to comply with Google Consent Mode V2

Select the tag you want to add the addicional consent check.

For this example, we are going to use the 'Facebook Pixel' tag again:

Google Tag Manager interface showing Tags list with Facebook Pixel tag highlighted and green arrow pointing to it.

Go to 'Advanced Settings''Consent Settings' and select 'Require additional consent for tag to fire'.

Google Tag Manager settings showing advanced settings and consent settings with required consent checked.

Choose the additional consents based on the previously selected trigger (check the visual reference below):

Tag Manager Facebook Pixel consent settings showing options for additional consent types to require for tag firing.

Visual reference for mapping the Consent Pro categories with additional consents:

Triggering panel showing Essential, Marketing, Analytics, and Personalization Cookies firing to various storage types.

Add the additional checks to every tag inside Google Tag Manager that requires user consent.

11

Submit and publish the changes in Google Tag Manager

Click on 'Submit'.

Google Tag Manager interface showing tags list with a green arrow pointing at the blue Submit button.

and 'Publish'.

Google Tag Manager submit changes dialog with Publish button in the top right corner highlighted.
12

Confirm that the Google Tag Manager setup is completed in the Consent Pro app

Check the checkbox in the Google Tag Manager message within the Consent Pro app.

Popup message confirming all scripts are updated and instructions to update script categories in Google Tag Manager.

Done! That's it!