Tag Mapper

Home

Why is Tag Mapper important?

It's easy to lose track of how complicated your Google Tag Manager (GTM) account has become.

The image on the right shows a medium-complexity GTM account.

  • Too complex to hold in your head
  • Lots of overlapping paths
  • Some things impact lots of others
  • Some parts rely on each other

We can easily break our sites with Tag Manager - but we don't always have the tools to check what impact our changes might have

Use Tag Mapper to find Tag Manager mistakes

When you're planning on changing something - check what you might break

Select any part of your GTM account.

You'll see your starting point in purple, with arrows pointing away from it, showing what other parts of your GTM is depending on it.

When you find out something isn't working - check what it's relying on that might have broken

Select any part of your GTM account.

You'll see your end-point in purple, with arrows pointing towards it, showing everything it is depending on.

Switch on-and-off nodes as you confirm they aren't a problem

You can click nodes directly, or tick them off a list.

When you switch off a node - the others on that chain will automatically be switched off too.


Visualise the account as a jumbled graph or tree-diagram

How to use Tag Mapper

  1. Export your current setup from GTM (I've written instructions here)
  2. Load the file to this page (or try the example data)
  3. Use the filters to select the variable, trigger, or tag you want to investigate
  4. Use the subfilters as you narrow down your investigation

Don't worry about remembering all of this - just start by picking your data, you'll get reminders of the instructions on the next page.

What Tag Manager links can this tool find?

This page will process your GTM markup and map our your Variables, Triggers, and Tags. It can currently identify the following links;

  • When a Variable references a Variable
  • When a Trigger references a Variable
  • When a Tag references a Variable
  • When a Trigger activates a Tag
  • When a Trigger, Tag, or Variable, have no clear links to any other element

There are also a couple more experimental features which could come in handy. This script will try to identify whenever a Tag or Variable use either dataLayer.push or document.cookie

You will be able to optionally highlight any anything which seems to be setting a cookie or creating a dataLayer event.

The tool will also look for other elements in your GTM which seem to reference the same dataLayer event or cookie name. So you can see;

  • When a Tag or Variable sets a cookie that's referenced in another Variable
  • When a Tag or Variable creates a dataLayer event which can cause a Trigger to fire

This script does not attempt to pick apart things like dataLayer conditions, i.e. "trigger fires on all formCompletion events but only where the dataLayer element 'order value' is > 100". The purpose of this tool is to let you visualise what might be impacted if you make as specific change, and tick off possible impacted elements as you confirm that they aren't affected.

Is my Tag Manager data safe?

None of your data leaves your computer or this page - it's all processed in your browser. Honestly, this is as good for me as it is for you - I wouldn't want to handle the storage.

As an aside - your Tag Manager export does not include any of your actual Analytics data - it's literally just setup, so all of this information is just the kind of thing people could work out by examining your website, if they wanted.

If, for some reason, you want to show your graph to someone without giving away specifics of names you can click here to anonymise

 variable
 trigger
 tag
 selected
 no connections
 external action

How to use this tool

Your Tag Manager data will automatically load in the jumbled graph view.

To switch to the tree-diagram view, toggle the "external connection" highlighting, or change other things about how the graph looks - click on the buttons hovering on top of the graph

The colour key for all the nodes is at the top of this page.

Searching

Use the Search tab to search for a specific element.

Tag Mapper will find anything in your Tag Manager account which contains what you type anywhere in its data. For example - if you need to find a tag called "pageview" you can type "pageview". If you need to find all tags which send a "conversion" event you can also search "conversion"

The results will be grouped into Variables, Triggers, and Tags. You can click on any of them to see more information and to filter the graph

Filter

If you don't want to use the search bar, you can investigate a specific element by clicking the Filter tab above.

Then select whether the element in question is a variable, trigger, or tag, select the element and then choose whether you want to find out;

  1. If I change this, what else could I break?
  2. If this is broken, what could have caused it?

The graph will only highlight the element in question, plus either the things depending on it, or the things it depends on, based on your selection.

Subfilter

As you investigate, you might be able to confirm that a specific group of elements don't matter at all. Maybe you have confirmed that you're not going to change anything they are dependent on, or you know they can't have possibly broken the thing you're looking at.

To remove specific items from the list - either just click the element in question on the graph or click the Subfilter tab and untick all the elements you know will be fine.

If you untick a specific element and that means a whole bunch of other elements are no-longer at risk, those will automatically be removed too.

Originating node


Variable

Trigger

Tag