An important component of website tracking is Google Tag Manager (often referred to as GTM). If you are a website owner, GTM may be invisible to you as it works ‘behind the scenes’ to deliver data to Google Analytics and other platforms.

GTM code snippet is installed in website

In the world of marketing measurement, GTM allows your measurement to be customised to your particular website. Every website is different, with different ‘calls to action’ (the actions you want our users to take). Most websites are also changing frequently to present new content and new offers to the audience.

Why do you need Google Tag Manager as well as Google Analytics?

GTM answers questions that can’t be answered with Google Analytics alone, by allowing you to track pretty much any action on your website. For example, form submissions, video views, and perhaps specific button clicks or specific navigation sequences that are important to you. You may want to assign ‘goal status’ to some of these actions so that you can look more closely at the attributes and behaviours of the people who carried out these actions.

What’s more, if you are using GTM, you don’t need to ask a developer to add code to your website each time you want to track something new, as it is all done within the GTM account.

As a website owner, why should you care?

Although you may not be working with GTM yourself, it is good to understand its capabilities, especially if you are driving decisions from data.

Website owners should also be aware of who has user permissions to important accounts such as Google Analytics and GTM. Make sure you have administrator access. You will need a Google account in order to have access. If someone else has set up these measurement tools for you, they should add your Google account as an additional administrator. Then you will always have access, and will be able to add and remove other people’s access.

How can you tell if GTM is installed on your website?

I recommend Google Tag Assistant (Legacy) for this job. It is a Chrome extension – you can Google it and install it on your Chrome browser. Then open any page of your website, click on the Tag Assistant icon, enable it, and then refresh the website page.
You will see whether Google Tag Manager is installed:

Google Tag Assistant

Understanding your GTM account

A Google Tag Manager account is structured like this:

  • Account
    • Container
      • Tags, Triggers, Variables

One container generally relates to one website. Within the container are tags, triggers and variables. These are the components that do the work of sending data to other platforms when someone visits your website.

Triggers, tags and variables work together

Tags, triggers and variables are created in the GTM web-based interface. In the container, you will see a menu on the left that includes Tags, Triggers and Variables.
Don’t be put off by the three zeros in the middle under Workspace Changes. Zeros here are good – that means there are no in-progress changes that have yet to be published.

Google Tag Manager home screen

GTM Tags

Click on the Tags menu item to see the tags. Tags you will see most often in a GTM container are sending data to:

  • Google Analytics (Universal Analytics)
  • GA4 (the new version of Google Analytics)
  • Google Ads
  • Facebook

The role of each of these types of tags is slightly different. Google Analytics and GA4 are analytics platforms, so the tags are for tracking website traffic and actions. Tags sent to Google Ads and Facebook are likely to be conversion tags. They send data when conversions happen on your website, so that these platforms can correctly attribute conversions to their Ads and report back to you. Conversions are the things that you have designated as the goals of your website. Online purchases on the website are also counted as conversions.

The tag type will tell you what kind of tag each one is.

In the Type column, for Google Analytics, there will be Universal Analytics tag types. One of these will be triggered on ‘All Pages’ and others may be triggered by specific events.

For GA4, you will see a GA4 Configuration tag and GA4 Event tags.

For Google Ads, you will see Conversion Tracking tags and possibly Remarketing tags. If there are conversion tags, the container will also need a Conversion Linker tag.

For Facebook, you will see Facebook Pixel tags. One will be triggered on ‘All Pages’ and others may be triggered by specific events.

Tags triggered by events usually represent conversions that you want to track, e.g. form submissions, email address clicks, phone number clicks.

The tag name may also reference the tag type if the implementer has used a consistent naming convention for tags. For example, they may have prefixed the tag name with ‘GA’, ‘GA4’, ‘GAds’, ‘Fb’ or similar.

GTM Triggers

Click on the Triggers menu item to see the triggers.

Triggers are created so that the tag will be sent when a specific event or user action happens on the website. They include condition statements that specify when a tag should fire.

Often you will see the same triggers being used across tags that send data to Google Analytics, Google Ads, Facebook and other platforms, as usually we want to record the same conversions in all platforms.

Triggers need to be thoroughly tested. In order to get accurate data, the trigger must always fire when the desired user action happens, and never fire for any other action.

Examples of triggers commonly seen in a GTM container:

  • Pageview of a specific page
  • Click
  • Link clicks
  • Visibility of an element on the page
  • Video view
  • Form submission
  • Scroll depth
  • Custom event

GTM Variables

Click on the Variables menu item to see the variables.

You will notice that they are divided into Built-in variables and User-defined variables. One of the first things you need to do in a new GTM container is configure the Built-in Variables by selecting those you want to use.

Variables are essentially formulae. Depending on where they are applied, the output will vary, as the name ‘variable’ implies. A simple example – the variable ‘Click Text’ will look for the text that the user clicked.

Variables can be used in tags and in triggers.

In tags, a variable can be set to define a constant that is re-used often. Most GTM accounts will use a ‘GA Settings variable’ to hold the Google Analytics tracking ID (UA-xxxxxx) and any other information that you want to send with every tag.

Variables can also be used to pick up a piece of information that is variable, and pass it in a tag.

In triggers, variables can be used to specify the conditions when the trigger should fire, for example:

  • Page Path starts with /contact-us/
  • Click URL starts with https://bookings.bookingengine.com

The Data Layer

The Data Layer is an important ‘middle layer’ that allows data to be transferred from the website and made available to GTM. When a website has GTM installed, the Data Layer will be populated with data with each new page load.

While some of this data is populated by default, the website developer can send additional data to the Data Layer, making it available to be picked up by GTM. You can send pretty much any data from the website to the Data Layer.

There are standard schema for some types of data, e.g. ‘Enhanced ecommerce’. Standard formats enable data to be understood by Google Analytics and displayed in the Ecommerce reports.

Preview and Debug Mode

Preview and Debug lets you test tags before you publish them, and to troubleshoot published tags.
When you open Preview mode, the website opens in an adjacent tab. As you interact with the website, the Preview and Debug view shows you events as they happen, tags that were fired/not fired, trigger conditions that were met/not met, variables available to GTM, and the progression of data available in the Data Layer.

What can I track with GTM – some common use cases

You could track email address clicks.

  • Example trigger: ClickURL contains tel:

You could track phone number clicks.

  • Example trigger: ClickURL contains mailto:

You could track form submissions. There are a few ways you could do this, depending on the form itself and the workflow. The trigger could be based on a pageview of a thank-you page, or ‘element visibility’ when a thank-you message displays in place of the submitted form. Some forms push a ‘form submit’ event to the Data Layer and this can be tracked as a Custom Event.

You could track video views – GTM has a built-in trigger for YouTube video views. As well as tracking start and completion, you can track progress milestones where you can specify percent or seconds viewed.

You could track Ecommerce events. This requires that events are pushed to the Data Layer, e.g., ‘purchase’ event. The accompanying data must be in a standard format for the receiving system to understand it (Google has published a specification for ‘Enhanced ecommerce’). The GTM trigger fires on the event and the tag picks up the ecommerce data and sends it to the target platform.

Where to from here?

Now it’s up to you to decide – are you happy to understand what Google Tag Manager can do at an overview level, or do you want to learn to use this tool? If you want to learn to use it yourself, you will find some very comprehensive courses online. Be prepared to take some time and practice to really get to grips with GTM. If you would prefer to hand this over to somebody else, I may be able to help. See my Google Tag Manager Services and get in touch for a chat.

Feature image by Helena Hertz on Unsplash