A drawing of a person sitting with their legs crossed, using a laptop. Around the drawing are lines connecting to another drawing of blue and white blank shopping tags. Above the drawings, in black bold letters reads, How to Set Up Google Tag Manager in 2024.

If you are a digital marketer or a data analyst, and you want to implement marketing and analytics tracking codes much faster, then Google Tag Manager is what you need.

What is Google Tag Manager?

Imagine you’re working for a company or an agency that helps different businesses, all of which have websites. It’s vital to gauge how well these websites are doing. One of the top tools for this job is Google Analytics. While Google Analytics is relatively easy to install on any website, it has limits. Custom data tracking to get around those limits is much more complicated. Before, this task required a developer to create the data tracking tags for your site. The only issue is that developers might not be as savvy with analytics tools as you are. Manually setting up tracking codes with a developer takes a while, involving a lot of back-and-forth. Plus, many developers have other priorities, and analytics might not be their top concern most of the time.

This is where Google Tag Manager can be very useful.

Google Tag Manager lets us take control of tracking codes on your own. Here’s a simple breakdown of how it works: you’ve got your website, your developer sets up Google Tag Manager, and then, you handle your tracking codes and all future analytics setup inside Google Tag Manager without the hassle of talking to a developer, ultimately saving everyone time.

What are the benefits to Google Tag Manager?


With Google Tag Manager all of the tracking codes are in one place. It’s much easier to find, manage, pause, or change your tracking tags.


Google Tag Manager makes you less dependent on developers. You can create very complex tracking codes without having to rely on your team.


Again, without having to rely on a developer, makes it so you can create data tracking tags at a significantly faster pace.


Google Tag Manager has a massive community of users and experts. This means there are bound to be numerous tutorials and resources at your disposal to create complex tracking tags for your goals.

Getting Started with Google Tag Manager

To get started, visit tagmanager.google.com. If you have never used Google Tag Manager before, you will see a screen for creating an account; otherwise, you will land on a dashboard. In the account creation funnel, there are two main components: the account section and the container section.

The Account field is just the name of your business.

Below that, you have your containers. Containers are like buckets for storing your tracking codes. You could have separate containers for multiple platforms, such as websites, mobile apps, and servers. For this tutorial, we will be focusing on web tracking.

Once this is finished, you will see your container. Open that container, and you will see a dashboard. On the left side, there are many important sections that you will be interacting with frequently. There are Tags, Triggers, Variables, and Folders. So, every time you need to create a new tag, you will go to Tags, then click New and follow the process. You can also organize your tags, triggers, and variables into folders. This is helpful for staying organized if you will be creating many different tracking tags using Google Tag Manager.

In the top menu, there are multiple sections. Workspace is where you will spend the most time, and Versions is where you will be able to see a full history of changes you’ve made to the site’s codebase while using Google Tag Manager. This is helpful if something goes wrong; you can always undo changes by going back to old versions.

Creating your First Tag

Before creating a tag, it is important that you create a Google Analytics 4 account. If you do not already have one, you can create one at analytics.google.com.

In your Google Analytics 4 account, go to AdminData collection and modificationData Streams. Here, you will find your website. Click on your website data stream to access more stream details. On this page, there is a unique ID number called “Measurement ID.” The code will start with a “G” and contain several numbers and/or letters, for example, “G-1XXX993XXX.” You will need to copy this Measurement ID for your first Google Tag in Google Tag Manager.

Now that you’ve found and copied your Measurement ID from Google Analytics 4, return to Google Tag Manager. Click on Tags, then New, followed by Tag Configuration. Click on Google Analytics, and select Google Tag. This is where you will paste the Measurement ID from Google Analytics. After pasting this, click on Triggering below, then select Initialization All Pages. You might find older guides suggesting to click All Pages, which should also work fine. However, the current recommendation is to click Initialization. Once these steps are complete, in the top left corner, you will need to name the tag; I suggest “GA4 Configuration,” then click Save.

You have now created your first tag in Google Tag Manager!

Testing your Tags

When you make new changes in your container, do not click submit right away. First, you need to ensure that your changes are working on your website.

For this example, we are checking if Google Analytics 4 is working on the site properly. Click on Preview in the top right corner, then enter or paste the URL of the page where you want to test your changes, and click Connect. Once you see that the tag assistant has connected, and you are now on the page that you entered, go back to the tag assistant tab, and click Container Loaded on the left side. You should see in the Tags Fired section that the GA4 tag you created has successfully fired.

You can also check if the tags you set up on Google Tag Manager are working on GA4. Go to your Google Analytics property, then Admin, and scroll down until you see Debug View. Here, you will see your events. If you do not see any events right away, give it a minute; sometimes, newer analytics properties take a bit more time for the debug view to begin working.

There is also a preview mode that opens on Google Tag Manager. On the left side, you will see a stream of Google Tag Manager events. These are not Google Analytics events; they are all related only to Google Tag Manager. All interactions while testing should appear in this left sidebar. You can click on these items to see more information about the tags. These tag details can help you troubleshoot any issues if the tag is not firing. If the tag is successfully firing, you will see green check marks under “Firing Triggers.”

Publishing your Tags

Now that your first tag is created, you must publish the tag. To publish your tags, there is a Submit button in the top right corner of Google Tag Manager. After clicking submit, it is good practice to write a version name and a version description. For this example, it can be something like “GA4 Setup.” If you do not provide these details for your tags, a year from now, it will be difficult for you to find what changes were made when looking at your workspace versions.

Once you’ve written a name and description, click publish, and the container is now updated to version 2. You can always find a history of your versions and changes under the Versions tab in the top menu.

If, for some reason, you made a mistake or an error, you can always roll back to previous versions in the container. You can do this by clicking on the three dots on the previous version, then click Publish, and click Publish a second time.

What can I use Google Tag Manager for?

There are so many things you can track in more detail using Google Tag Manager. One of my favorite things to track is clicks on specific buttons on a website. Google Tag Manager can also track much more, like form submissions, video interactions, file downloads, outbound and internal link clicks, custom JavaScript events, scroll tracking, and social media interactions.


This general process should be repeated every time you use Google Tag Manager. First, you create tags, triggers, and variables for the data you want to track. Then, you use preview mode and debug view to make sure the triggers and tags are working properly. Once everything is working properly, you submit your new version to the container after all of your data will begin collecting and eventually appear within your Google Analytics account.