The 12 Days of Data: 7 Tags A’Firing

December 16, 2013

On the Seventh Day of Data my true love gave to me. . . Seven Tags A’Firing

6 Golden Goose Eggs
5 UTMs
4 Advanced Segments
3 French Fans (Viewed in GA Real Time)
2 Profile Settings
And an Unsampled GA Data Set

I get real fired up when I think about all the possibilities we have with Google Tag Manager (pun intended). Compared to the accuracy, flexibility, and rapid turnaround time that using a tag management system like GTM provides, the process of manually writing analytics tags seems as old as this song.

Google Tag Manager is such a powerful tool that it can quickly become a bit overwhelming. Here are seven steps it takes to get all your tags a’firing.

Create An Account & Container

Before you can do anything with GTM you’ll need an account. If you’ve got a Google Account it’s free to make a new GTM account and container here. During the account creation process you’ll be asked to name your account and container. Before you go crazy setting things up, think through the scope of the implementation you are working on. If you manage more than one site, should a single container run across all of them or should each site have its own container? Are there multiple regions working with a common site that should each get their own container?

The goal here is to scope out the business or technological borders that exist and align them with your tag management layout.

Make Some Tags

Now the real work begins. The backbone of Google Tag Manager is the tags you are going to be deploying. It’s a good idea to sit down with everyone and get an idea of how many tags will be served by GTM before setting things up.

Once you are ready to start, click the new tag button in your container draft:

This brings up an easy-to-use form that contains all of the settings you’ll need to configure a wide array of tags. Tags are loosely grouped into two types, template tags and custom tags. A wide array of common tags are supported directly within GTM with no coding required. Just fill in your account ID, etc and you’re done. If your tag isn’t supported with a template, don’t worry. Google Tag Manager can support virtually anything using custom HTML tags.

Select the tag you are interested in and go from there.
GTM Tag Categories

Write Some Rules

Before Google Tag Manager will serve any tags, you need to give them a rule. This can be as simple as All Pages (ideal for your core Google Analytics tags) or match a conversion page (for conversion pixels). There are tons of ways that you can write rules, but keep in mind that every condition needs to be met within a rule for the rule to be counted as true.
GTM Add Rule(s)
If you happen to have two conditions that you want to fire your tag under and you don’t care which condition is met, define two rules and add them both to the tag.

Lastly, if there are any conditions that you want to set to prevent your tag from firing, use a blocking rule. In a showdown blocking rules always win. So if you want to fire a tag on All Pages except one, add two rules: one to fire on all pages and one to block the tag from firing on the oddball page.

As you plan out your rules there is one major gotcha: rules are only evaluated when a page loads or when you send an ‘event’ to Google Tag Managers dataLayer. So, keep in mind when and where you want your tags to fire.

Get Some Data (Macros)

A plethora of information is constantly being passed back and forth on the web, and Google Tag Manager can grab a ton of it using Macros. A macro is just a pointer to a particular piece of data. That data could be held in the dataLayer, a cookie, some javascript somewhere, etc.

The great thing about macros is that they are highly portable. You can use them in tags to provide just the right data (i.e. transaction totals) or in rules to match dynamic conditions (button clicks).

Test, Test, Test

Now that you have an awesome container full of tags with rules and macros its time to test. Built into Google Tag Manager is a powerful debugger. Use the preview drop down to preview and debug your container draft then visit your site. A popup will appear at the bottom of the page to tell you what tags have fired and what triggered them.
GTM Test the New Container
Surf your site and confirm that all of your tags are firing when and where they should.

Make a Version

Now that you’ve confirmed all is well, create a new version of your container. This takes all of your changes in the container draft and wraps them up into one neat package to put under the tree. The nice thing about versions is that they don’t go away. You can always go back to a previous version to start over or roll back time in the (unlikely) event that something breaks.


With your new version in hand it’s time to share it with the world. Once you push the publish button everyone who sees your site will get the new version of the container, complete with your awesome changes and all those tags a’firing.

Happy Tagging!