The Complete Guide to Google Tag Manager (GTM)



Google Tag Manager

GTM basically allows you to collect the data you need to make smart marketing decisions. At first, GTM might seem rather complex although it is not that complex once you grab your head around it therefore, we have decided to put together this guide to help you out.  They want brands to feel their challenges and celebrate their wins. They want brands to feel friendly, comfortable and trustworthy. It’s a feeling of “Yes, this is me” that taps into customer identity and lets brands establish connections almost like friendships.

Why Google Tag Manager is Important

First of all, we need to understand what tags are. Tags are basically snippets of codes added to webpages to collect necessary data and information. They help us monitor website and user activity so that we can optimize our site based on these data. This data can involve anything from the age group or location of our visitors to their behaviors on the website like how much they spend, what pages are more popular amongst our visitors etc.
Most websites need various tags in order to track different behaviors. But the more tags you implemented, the more challenging it can be to manage.
Hence, GTM.  They want brands to feel their challenges and celebrate their wins. They want brands to feel friendly, comfortable and trustworthy. It’s a feeling of “Yes, this is me” that taps into customer identity and lets brands establish connections almost like friendships.

GTM lets you add and manage these snippets without having to need a developer or manually adding the tags to a website and set unique rules for each instance. Once these tags are manually added to a website, they’d have to be manually checked, fix the issues, discard expired codes and so on. This is naturally time consuming and costly because generally you would have to hire a developer or at least outsource it.

But not with GTM.

Tag Managers in general, they minimize the effort and amount the codes you’d have to implement across your website and allows you to house all codes needed in a “hub” where you can keep up with all the snippets you have, run a test shoot to see if there is any error with them and the best part is you can customize them by adding variables which we will get to it later on this article.

GTM is completely free so that is another benefit of this tag management tool.

However, mistakes happen, and they will keep happening.

To keep costs down we offer you to practice these steps:

Decide what you actually need to track, rather than implementing a coed that would track data you won’t need and analyze.
It is better to avoid piling lots of codes on every page otherwise the page is going to slow down.
Make sure the discard or disable tags you don’t need anymore to keep the page fast.
Avoid deploying custom HTML codes that may break the running tag.

GTM doesn’t have reporting capabilities, instead it will send the data it collects to Google Analytics to be analyzed.

How to Set Up GTM

1.Start with your goals

First step towards setting up the GTM is to decide what do you expect from it. This means that you should define your goals. You can create tags for marketing, remarketing, conversion tracking, monitoring form submissions, button clicks, calls and so on.

2.Set up an account

As if it is with anything Google related, setting up a GTM account also needs to be done through your Google email.
Log in with your Google account, then click Create Account on the dashboard to begin.

Then you are going to name the account. We recommend you to name it after your business to keep it tidy and organized. Then you need to create your container. A container is basically where all of the tags will live. It is pretty self-explanatory really. So, you should name it after your website or URL. Then as for the target platform, choose the type of platform where your website or app lives.

Afterwards, you need to install the container snippet onto your website. This snippet needs to live on every page your website has therefore you should add this code according to that in order to collect and properly track the activity.

To add these tags to your website you’ll need to,

Paste the first code as high in the of the page as possible.
Paste the second code immediately after the opening tag.

There are three main sections/panels you’ll see in the sidebar of your GTM dashboard. These are tags, triggers, and variables.

Tags are the tracking codes that collect data from a website or app. So basically, what do you want GTM to do?
Triggers set conditions to tell a tag when to fire. When do you want to trigger the tag?
Variables define when triggers should alert tags to run.

3.Install the Google Analytics tag

Keep in mind that if you decide to do this with GTM you will have to delete any Google Analytics tracking tags you previously implemented on your website. Otherwise, you are going to have some duplicate data.

Click “Add a new tag” on your dashboard to begin with. For the Google Analytics purposes it is best to name it something explanatory like “GA Pageviews”

Next, we should configure our tag. To configure it we will click the top box and a list of more than 50 items will present itself.

Depending on which version you are using choose either Google Analytics: Universal Analytics or Google Analytics: GA4 Configuration.

Under the Tracking Type dropdown, click Page Views

4.Set up Property Variable

There are 2 options when setting up a variable. First, you can choose “enable overriding settings in this tag” and paste your UA tracking ID.

Or, it is possible to create a custom variable. Though it takes more initial setup, it will make things easier in the long run because what it does is to keep your UA tracking code stored so you would not have to paste it in every tag you create.

There are 2 different types of variables GTM offers:

Built-in variables
User defined variables

With built-in variables, GTM will automatically define these variables based on what is presented in the code snippet. There are a few basic common variable types offered so it is rather easy to create basic tags.

Click Configure to set up each variable you are going to need in the future. You can always come back and add more.

User-defined variables are custom so you can create a constant variable that stores your Google Analytics Tracking ID. To do this, click New under the User-Defined Variables. Then scroll down until you spot Google Analytics Settings.

Paste your Tracking ID into the field and then save.

Now, since we have done all these, we don’t have to check “Enable overriding settings in this tag” button. Instead, we can just open the dropdown and select a new variable.

5.Configure Your Trigger

We have come to the final step in regards of activating the first tag: choosing a trigger that will fire the tag.

To do this, we simply click on the Triggering box and select All Pages from the options. Then click save.

To get our tag officially running we have to Submit our workspace changes. You’ll likely have these two: one new tag and a new variable.

6.Set Up cross-domain Tracking

If your business’s flow leads customers to different domains, then it is best to integrate cross-domain tracking so that our tracking code counts them as one instead of inflating the data and counting each one of the domains they lend on. Although, this isn’t necessary for subdomains, it is necessary only when you have two entirely different domains that work together.

It is rather easy to set up cross-domain tracking. You can set it up at the tag level by checking the Enable overriding setting in this tag and accessing Cross Domain Tracking, but the best to do this is in your Google Analytics ID Variable.

7.Understanding the data layer

The data layer basically acts an intermediary. It is a JavaScript code snippet that stores the data from the website before sending it to GTM.

Having a data layer helps your data collection process become smoother. For most tags you don’t have to do anything extra but for some tags like e-commerce conversion tracking you’ll need to set up a data layer.

In order to do this, you need to create a data layer variable. This will help GTM to read additional values from the website and pass it through to your tags.

Unfortunately, you are going to need a development team to assist you with this process. They will help you create and implement a data layer code snippet for each page you want to track additional information for. These must be done page by page.

8.Plan for user management

Depending on who needs access, you can add or remove users from your GTM. To do this you need to go to the Admin tab then click the User Management option.

There are two types of users you can add to your GTM:

Admin: Can create and remove containers and manage user permissions.
User: They can view basic account info and access only allowed containers.

Utilizing GTM Effectively

  • There are a few tips to help you operate your GTM more effectively.
  • Make sure your GTM code runs on every page
  • Track the events that you need (form submissions, button clicks, sign-ups etc.)
    To do this, you are going to need to create another Google Analytics: Universal Analytics tag but this time choose Event from the Tracking Type tab.
  • Debug your tags
  • Monitor your tags in order to check if there are any problems with it. To do that, use the Preview and Debug Mode.
  • Create constant variables
  • Install extensions
  • Create a tag naming process.


To conclude, it is safe to say that it’s time to start practicing everything you have learned there. This can be creating a simple tracking tag for your website to see if the data reflects on Google Analytics. We would recommend starting with whatever is more important for your website so that you can benefit from your effort.

Our Services


PPC Service

Highlights Post


No Content Backlinks Ranking Tactics