Last updated on July 31, 2021, 2:26 PM
What is Google Tag Manager (GTM) and what can you do with it?
The Google Tag Manager, or GTM for short, is another tool that Google provides for free to make life a little easier for online marketers. With the GTM you have the opportunity to easily and conveniently insert so-called tags (mostly Javascript code parts) onto websites during ongoing operation and thus set up your analysis setup and edit it on an ongoing basis.
What are these tags exactly, or what tags are there?
A tag is usually a Java Script code that has a certain analysis task and essentially “sends home” information. The easiest way to explain it is still with Google Analytics. Google Analytics is a web analysis system that is used on a variety of websites and applications and is simply integrated into the HTML code of the website.
For example, the Javascript code from Google Analytics looks like this:
<!-- Google Analytics -->
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', 'GA_TRACKING_ID', 'auto');
ga('send', 'pageview');
</script>
<!-- End Google Analytics -->
This code is used to collect data on the website from visitors and send it to Google.
In addition to the Google Analytics code or tag, there are a variety of other tracking codes or tags](https://support.google.com/tagmanager/answer/6106924?hl=en). For example from Adwords, DoubleClick, or special remarketing systems. All of these tracking codes usually also set a cookie. To see which pages use how many of these codes/tags when they are surfed, you can view the whole thing with the browser extension Ghostery.
You’ll be surprised at what’s happening on some pages here :)
What does Google Tag Manager actually do for me?
The installation of the Javascript codes and changes to them previously had to be done “by hand” and you either needed FTP access to the website to edit the HTML / PHP files or access to the CMS. With every change you had to change the HTML file and upload it again to the FTP server.
In CMS systems such as WordPress / Typo3 etc. there are also resourceful developers who have designed plugins and extensions to make the installation of tracking codes / tags as easy as possible for users. But every time you made a change you still had to log in again and change the code. The whole procedure was quite tedious, especially with more complex tracking setups and online shops.
The Google Tag Manager now goes one level higher and offers a management system for most common tracking codes/tags. The big advantage now is that you only have to install the Google Tag Manager code once and then you can make all other changes, including adding other tags (Facebook, Adwords, …) conveniently from the Tag Manager interface.
This also means that you only have to ask the webmaster or the responsible person to install the GTM code once and then it’s quiet :)
The GTM Container System
You can imagine how the GTM works like this:
- You create a container by installing the GTM code on the website
- All other tags simply go into this container
- All tags in this container are easily managed via the GTM interface
You can see this nicely displayed in the Tag Manager interface. After you have created an account, the first thing you do is create a container.
You can then select various tags (see image above) and insert them into your container.
A short guide to inserting and installing the Google Tag Manager code in WordPress will follow soon here -> coming soon: Install and use Google Tag Manager in WordPress.
The advantages of Google Tag Manager
The advantages of using the GTM summarized again:
- Easier installation of tracking codes/tags
- Easier management of tracking codes/tags
- Traceable change history when installing tracking codes/tags
- Using version control you can see exactly when which code was added by which user
- Lower loading times = faster website
- Due to the fact that fewer individual tracking codes / tags are installed, the page loads faster
- Testing options when installing new tracking codes / tags
- Using Preview and Debug Mode you can first test the installation before switching everything “live”.
So there are a lot of advantages that you have with the GTM. For me there are actually no disadvantages, which is why I always recommend switching to GTM instead of installing individual tracking codes.
Set up and install GTM
Setting up the GTM is relatively easy. Especially if you already have access to the website files via FTP. Otherwise you have to ask the respective webmaster to carry out these steps.
-
Visit https://tagmanager.google.com and create an account
-
Assign account name and in the next step
-
Assign container names
-
Choose whether you want to set up the container on a “Web” website, in an “iOS” / “Android” app, or on an “AMP” accelerated mobile page. In most cases it will be a website, so select “Web”.
-
Agree to Google’s terms
-
Install the two Javascript code elements on the website ATTENTION: A code element goes in the
element of the website(s) and a code element is intended for the part. -
Then select a day -> in most cases the first day you use will be Google Analytics Set up the 8th day -> a detailed explanation will follow shortly in a separate blog post :) 9th day previews, and check whether everything works as it should in debug mode
-
“Submit” the changes and thus the new version and thereby go “live”.
If you use WordPress, I also have short instructions here for installing the Google Tag Manager in your WordPress installation.
This would be a quick run-through so you can imagine how setting up a tag works in GTM. The long version with detailed explanations will be available here shortly. Until then also feel free to sign up for the newsletter so you don’t miss anything :)
If you have any further questions, please feel free to contact me -> Contact.