InsightsAnalyticsGoogle Tag Manager Best Practices (Part 3 of 3)

Google Tag Manager Best Practices (Part 3 of 3)

These best practices fall into four main buckets.

In my first and second articles, I covered getting started with Google Tag Manager and coming to grips with its advanced features. In this final part, we will cover a series of best practices to ensure that you start using Google Tag Manager correctly from day one. Following these best practices will save you from many headaches in the future.

These best practices fall into four main buckets:

1. Naming conventions

2. User management

3. Maintaining extensive history notes

4. Staying up to date

1. Naming conventions

As you create tags, rules, and macros, you are allowed to name them however you wish. While this flexibility is great, the list can get unwieldy as many users start creating tags, rules, and macros in the same account. By implementing a standardized naming convention, however, you can ensure three things:

  1. You can find the tag, rule, or macro that you are looking for
  2. By just looking at its name, you can tell what a tag, rule, or macro is supposed to do
  3. You minimize the risk of creating duplicate tags, rules, or macros

Tag naming conventions

Tag names should be a combination of what the tag is, its purpose, and where the tag is being fired. The naming format should be:

{Tag type} – {Purpose} – {Firing locations}

Let’s take a look at a few examples.

Scenario: Facebook conversion pixels for your sales confirmation page and newsletter subscription confirmation page

Let’s say you have an e-commerce website that fires two different Facebook conversion pixels when a sale is completed and when a visitor signs up to your newsletter. You may wish to name your tags like so:

  • Facebook conversion pixel – Conversion – Sale
  • Facebook conversion pixel – Conversion – Newsletter

Scenario: Standard Google Analytics tag across all pages

This is an easy one – name your tag:

  • Google Analytics standard – all pages

Scenario: Google Analytics event tracking tag for when a user clicks on a photo in a gallery

Let’s assume you have a photo gallery on all your product pages and want to use Google Analytics event tracking to identify which photos are clicked on. We can define and fire an event tracking tag for that. The tag could be named:

  • GA Event – Photo Gallery clicks – Product Pages

Rule naming conventions

Rule names should reflect what the rule conditions are. Names should be of the form:

{Rule dimension} – {Match type} – {Condition}

Again, let’s take a look at a few examples.

Scenario: All pages under the /productX folder

  • URL – contains – /productX

Scenario: Data layer event equal to “photo_clicked”

  • Event – exact – photo_clicked

Macro naming conventions

Macro names should reflect where the macro is originating from (i.e., macro type) and the role that it plays. At the same time, however, you want to keep the names short so that you can easily reference them in your tags. Names should be in the form:

{Macro type}_{purpose}

Scenario: Data layer variable “conversionValue”

  • DL_conversionValue

Scenario: JavaScript variable “s.prop4” (reading an Adobe SiteCatalyst variable on the page)

  • JS_sProp4

2. User management

Users of Google Tag Manager hold great power by possessing the ability to manipulate tags on a site. A robust user management scheme must be in place to ensure that tags are deployed in a consistent and safe manner.

To achieve this, user roles must be tightly enforced. Google Tag Manager provides four levels of container level permissions.

  • No access: The user will not see the specified container in their container list.
  • View only: The user will only be able to view the tags, rules, and macros for the specified container.
  • View and Edit: The user can add and edit tags, rules, and macros for the specified container. They can create a new version of the container, but will not be able to publish it.
  • View, Edit, Delete and Publish: The user may add, edit, and delete tags, rules, and macros for the specified container. These users are also the only ones who may publish changes to the live environment.

The recommended approach for handling user permissions is:

  • At most only have two people, let’s call them “Super Users,” within the organization who have “View, Edit, Delete and Publish” permissions. This has two benefits. First, accountability is restricted to a few individuals, who in turn will take serious care in ensuring published tags are correct and do not affect site performance. Second, if an issue is found on the live site, it can be traced back to a few individuals for troubleshooting purposes.
  • Identify those who will be frequently proposing new tags and changes. Give them “View and Edit” rights. This allows them to go in and create new tags, rules, and macros without having to rely on anyone else. Once they have set up the changes, they can create a new container version and verify their changes in preview mode. Once satisfied, they then ask a Super User to conduct final verification and publish the changes if they are happy with them.

3. Maintaining extensive history notes

Whenever a new container version is published, you are given the opportunity to name the container version and add notes. You should take advantage of this facility to leave full notes for someone who may be auditing your site’s tagging or troubleshooting your changes at a later date.

It is recommended that you:

  • Give the container a meaningful name that reflects the additions and changes made to it.
  • Provide detailed notes that include:
    • Who requested the changes
    • Who published the changes
    • What are the new tags, rules, and macros in this container
    • What changes were made to existing tags, rules, and macros

Here is an example:


4. Staying up to date

Google Tag Manager is still in beta, and many changes roll out on a regular basis as Google strives to make it a more flexible solution. Thus it’s important to keep track of what’s new so that you can take advantage of the latest features as they come out. Keep an eye on these resources to stay informed:

Google Tag Manager is a powerful solution, and as you start to use it, your list of tags, rules, and macros will grow. The proliferation of new marketing and tracking tags almost guarantees this. Following these best practices will ensure that you are able to maintain a manageable set of Google Tag Manager accounts and containers as your usage develops.


US Mobile Streaming Behavior

Whitepaper | Mobile US Mobile Streaming Behavior


US Mobile Streaming Behavior

Streaming has become a staple of US media-viewing habits. Streaming video, however, still comes with a variety of pesky frustrations that viewers are ...

View resource
Winning the Data Game: Digital Analytics Tactics for Media Groups

Whitepaper | Actionable Analysis Winning the Data Game: Digital Analytics Tactics for Media Groups


Winning the Data Game: Digital Analytics Tactics f...

Data is the lifeblood of so many companies today. You need more of it, all of which at higher quality, and all the meanwhile being compliant with data...

View resource
Giving a Voice to Your Brand

Whitepaper | AI & Automation Giving a Voice to Your Brand


Giving a Voice to Your Brand

Voice commerce, or conversational commerce, is a major disruptive opportunity in US retail. It opens up the possibility of building deeper relationshi...

View resource
Mobile Messaging Masters

Whitepaper | Mobile Mobile Messaging Masters


Mobile Messaging Masters

Every year the mobile market continues to grow and develop. Cyber Monday 2018 saw $2.2 billion in sales stemming just from smartphones in the United S...

View resource