Hammad Ashraf
5 min readDec 30, 2020

--

Credits: www.beautifulthemes.com/blog/google-tag-manager/

A Prelude to Google Tag Manager — Behemoth of a tool

“You live or die by the data you collect, and the quality of that data.” — Avinash Kauskik

This article will serve as a prelude to an upcoming series of articles on Google Tag Manager (GTM). I will try to answer some very common questions that beginners need to be aware of before jumping into the world web analytics.

Marketing analytics is not limited to generating custom reports from Google Analytics. At its core, marketing analytics practically calls for collecting data from the entire range of marketing channels, including paid and organic channels, and extract valuable insights that can drive business. Amplitude, Mixpanel, Adobe Analytics, Heap, KISSmetrics, and other traffic or event-oriented tools fall under the same umbrella. But who is responsible for collecting that data? What if you need more fragmented data , what if you want to track something the tools don’t track by themselves? These are the questions that GTM essentially answers. By using GTM in conjunction with our desired analytics tool, we’re able to collect much more data.

Many marketers are hesitant to start using GTM because it looks daunting. However, once you comprehend the basics, it becomes second language. Avinash Kaushik sums up the usefulness of GTM brilliantly:

“You live or die by the data you collect, and the quality of that data. The single biggest limiting factor in your ability to think smart and move fast when it comes to taking advantage of the latest and greatest features is tagging your site.”

What is it?

Google Tag Manager is a free tool that allows management and deployment of marketing tags (snippets of code or tracking pixels) on a website (or mobile app) without the need to modify the code. Be mindful of the fact that GTM does not store data like the analytics tools, GTM simply collects and routes the additional data to any analytics tool.

What is a tag?

A tag serves as an instruction for the tag manager. In short a tag says this to GTM “here’s what I want you to do, tell these platforms what has happened”.

CXL’s blog “ How “Tag Management Can Improve Site Performance” perfectly describe a tag.

When people talk about “tags” they’re talking about the snippets of javascript provided by 3rd party services like Google Analytics, DoubleClick, AdRoll, Adobe SiteCatalyst, etc. Every 3rd party tool like these you bring to your site to improve your ability to reach & serve customers means adding a new piece of javascript — aka a tag — to your site.

The diagram below shows where GTM falls in the marketing measurement process.

Source: Analytics Mania

Is GTM the only tag management tool?

Negative, GTM is just google’s offering for tag management. Some other options are:

  • TagCommander
  • UberTags
  • Adobe Dynamic Tag Management
  • Segment
  • 7tag
  • Tealium

Primary reasons to use GTM?

All under one roof

One of the primary reasons GTM should be used is that of centralization. This means you get to replace multiple code snippets on your website with one concise container. In absence of GTM, 3rd party tracking codes were hard-coded by a web developer on each individual page. In order to track hundreds of events, the process became tedious and error prone, plus maintaining or updating them became a hassle. Additionally, making future upgrades and enhancements can become a seamless process GTM and doesn’t need to be done through each page of the website.

Get your ideas tracked quickly

Source: Analytics Mania

Google Tag Manager speeds up many processes. Marketers themselves can deploy and test tags in order. Connection of tracking tools like Hotjar or Facebook pixel can be performed by modern marketers entirely skipping any need of developers. Moreover, GTM’s interface provides accessible testing and debugging modes that marketers can utilize to evaluate which tags are correctly fired on a page and which are not.

How is Google Tag Manager different from Google Analytics?

GTM is a completely different tool used only for managing third-party code. No data analytics can be performed through GTM as there are no reports or any way to do analysis in GTM. Google Tag Manager does not replace Google Analytics, instead it is the middle-man of digital analytics implementation on any website who can deploy GA event code snippets and define rules and firing triggers.

Components of GTM

Containers — It starts with me

A container is what holds all of the tags and triggers deployed through GTM. The Google Tag Manager container snippet is a small piece of JavaScript and non-JavaScript code that you paste into your pages. It enables Tag Manager to fire tags by inserting gtm.js. Any modifications to tags need to be published through the container. A GTM account can have multiple containers for different websites.

Triggers — When should a tag fire?

Triggers are basically conditions that need to be matched before a tag can be fired. For e.g. we want to have a tag do something when someone downloads a file, views a video or when a form is submitted. These sorts of events are known as triggers and all tags need to have at least one trigger assigned to it.

Triggers further depend on two main components: events and filters. When a trigger is configured a default list of events is provided by GTM to choose from. Once an event is chosen, we can set up a filter further narrowing done our conditions

Variables — I have more information

Variables are basically a form of information GTM to perform something at a specific time or value. While tags depend on triggers, triggers depend on variables. Variables contain the value a trigger needs to evaluate to know whether or not it should fire. Variables can also provide GTM with additional information. More on that later.

Steps to setup GTM

Step 1: Installing the Google Analytics Tag

Step 2: Setting Up the Property Variable

Step 3: Setting Up Cross-Domain Tracking

Step 4: Understanding the Data Layer

What’s next?

Google Tag Manager can definitely make your life easier if you are willing to spend time with it. In the upcoming GTM series, we will look into the details of various GTM components and will dive deep in the aforementioned steps to set up GTM.

GTM resources you should definitely follow:

  • Optimize Smart blog by Himanshu Sharma,
  • Bounteous
  • Simo Hava blog
  • Conversion XL blog
  • Chris Mercer, Seriously Simple Marketing
  • AnalyticsPros blog
  • Analytics Mania,
  • Avinash Kaushik

Published by

Hammad Ashraf

LUMS’18, Growth & Retention Marketer | Marketing Automation Specialist | Analytics & Data Enthusiast | Engineer

11 articles

--

--

Hammad Ashraf

An engineer turned marketer on a mission to create value for businesses — Growth Marketer | Marketing Automation Specialist | Analytics & Data Enthusiast |