GTM variable that removes PII from query string

Published on 2021-06-07 in GTM

This is my first GTM Template that I’ve added to the Template Gallery. What this variable does is that it allows you to modify a query string from the URL in order to make sure that you are not sending any PII by mistake to third party services. You can find the template on

Continue reading »

Tracking meta tags with Google Tag Manager

Published on 2019-01-15 in GTM

This is a very useful function that I have used quite a lot. Maybe you want to import the meta description for each page to Google Analytics or perhaps the developers have made some variables available in meta tags instead of using a data layer. Of course you could make the information available in the...

Continue reading »

Trigger event in GTM when mouse pointer leaves window

Published on 2018-03-27 in GTM

Wouldn’t it be nice to have an event in Google Tag Manager for when the mouse pointer exits the browser window? This can be achieved easily by implementing a listener with a custom HTML tag. The only thing you have to do is create a new custom HTML tag and paste the script below. I...

Continue reading »

Create custom UTM parameter names

Published on 2018-03-25 in GTM

Tired of having to type the entire UTM string each time you want to track a link? With this setup in Google Tag Manager you can create your own names for the UTM tracking parameters without losing the tracking of the standard ones. I’m gonna show you an example of why this is worth the...

Continue reading »

Simple function to add trailing slash and lower case in GTM

Published on 2018-03-25 in Analytics

Have you noticed that some of your pages are counted in different rows in Google Analytics? Two of the most common reasons to this are trailing slash and pages with different case types. Google Analytics imports the requested URI in the exact format that is typed in the browser. This means that if you visit...

Continue reading »

Remove possible PII query data in Google Analytics

Published on 2018-03-15 in Analytics

Have you noticed that Google Analytics page view data sometimes include query strings? There are a lot of positive aspects to this, e.g. the possibility to auto track AdWords, adding UTM parameters etc. But in some cases this could be a real headache. What if your website puts sensitive data in the query string? One...

Continue reading »

Adding Facebook pixels for multiple markets with only one tag

Published on 2018-01-02 in GTM

Are you tired of having multiple tags in your GTM for Facebook pixels in different markets? If you have a domain with different markets as subfolders (e.g. “.com/de”) then you probably are using one pixel tag for each market, i.e. if you have 8 markets on your domain then you use 8 different tags to...

Continue reading »

Cookie Settings

© Copyright - - 2018-2024