Free Google Tag Manager Custom Templates to Save you time and simplify your tracking setups
Here is a list of FREE Google Tag Manager (GTM) custom templates developed by the DumbData Measurement Resource Hub to help address various data collection challenges.
We currently offer 35+ templates for both Web and Server GTM containers, with several already Google-approved and available in the Template Gallery Community Listings.
The IP Transformer/Anonymizer
Anonymize IPv4/IPv6 addresses with multiple methods including removing octets, hexets for IPV6, redacting, or replacing with a static IP.
- TYPE:
- Server
- Approved By Google

- CATEGORY:
- Variable Template
Country ISO Code and Name Converter
A GTM variable template that converts country names to Alpha-2/Alpha-3 codes and vice versa, with advanced options for handling invalid or unrecognized input.
- TYPE:
- Server
- Web
- Approved By Google

- CATEGORY:
- Variable Template
US State Code and Name Converter
A Google Tag Manager (GTM) variable template that simplifies converting a U.S. state name to its corresponding abbreviation and vice versa.
- TYPE:
- Server
- Web
- Approved By Google

- CATEGORY:
- Variable Template
Microsoft Clarity Playback URL
A WEB Google Tag Manager (GTM) custom variable template that helps retrieve the URL for Microsoft Clarity session playback recordings for that user’s session.
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Variable Template
Basic Bot Traffic Identifier
Labels potential bot traffic as ‘potential_bot_visitor’ and non-bot traffic as ‘real_website_visitor.’ By default, bot traffic detection is enabled. You can customize this with your own rules.
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Variable Template
Variable Coalesce
A Google Tag Manager custom variable template that mimics the behavior of a coalesce function commonly used in programming. This variable checks a sequence of variables and returns the first valid value, supporting skip values and a fallback mechanism.
- TYPE:
- Server
- Web
- Approved By Google

- CATEGORY:
- Variable Template
Currency Value Formatter/Splitter
Google Tag Manager (GTM) custom variable template helps format and clean currency values. It removes specified currency symbols and codes, with support for custom symbols and delimiters.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
Advanced Traffic Labeling Rule GTM Variable
Google Tag Manager (GTM) custom variable template helps flexible traffic segmentation based on various rules, including domains, cookies, storage, query parameters, custom variables, dataLayer, IP address, etc. This template helps distinguish internal vs. external traffic based on user-defined rules.
- TYPE:
- Server
- Web
- Approved By Google

- CATEGORY:
- Variable Template
GTM Item Array Transformation
This variable template is designed to help you easily transform any array of objects (such as Google Analytics items array) by remapping attribute keys to a new format, providing you with enhanced flexibility, security, and functionality.
- TYPE:
- Server
- Web
- Approved By Google

- CATEGORY:
- Variable Template
Event/Pageview Cookie Counter
to count and track user interactions, such as pageviews, product page views within a session or across visits. It checks if a cookie exists, increments its value if found, or creates it if missing. Optionally, it pushes an event to the Data Layer upon execution.
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Tag Template
Array Attribute Transformer
A GTM variable custom template that extracts values from a specified attribute key in an array of objects and transforms them into an array of strings, integers, or numbers.
- TYPE:
- Server
- Web
- Approved By Google

- CATEGORY:
- Variable Template
FullStory Session Recording URL
Get the FullStory session recording URL for the current user’s session. This URL can be sent anywhere.
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Variable Template
Mouseflow Session Playback URL
This Google Tag Manager (GTM) variable template generates a Mouseflow session recording playback URL. The URL takes users directly to the session recording of a specific user’s session in Mouseflow
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Variable Template
Fullstory Advanced Unofficial
An unofficial Google Tag Manager custom tag template for FullStory. This template enables event tracking, user identification, setting user properties, and setting page properties seamlessly within GTM.
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Tag Template
Mouseflow Advance Unofficial
An unofficial GTM tag template for Mouseflow that can help with implementing Mouseflow tracking, such as applying tags, user identification, setting custom variables (with session scoping capability), tracking custom user friction, 404 errors, and measuring form interactions (submit, success, failure). It also supports installing the Mouseflow script.
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Tag Template
Siteimprove Analytics Unofficial
An unofficial GTM tag template for Siteimprove that can be used to implement Siteimprove, including installing the script, executing events, and tracking pseudo page load event (virtual page views).
- TYPE:
- Web
- Approved By Google

- CATEGORY:
- Tag Template
Smartlook Advanced Unofficial
An unofficial GTM tag template for Smartlook that can be used to implement Smartlook event tracking, identify users, set global event properties, trigger virtual page views, and track custom errors.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Tag Template
PostHog Utilities
Google Tag Manager Variable Template for retrieving PostHog session replay URL and session ID of a user’s current session.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
Microsoft Clarity Utility
This GTM Microsoft Clarity utility variable retrieves the Clarity session replay URL, session ID, or user ID for the current user session.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
Osano CMP Consent State
Use the template with the Osano CMP to detect an individual user’s consent state and configure when tags should execute. Useful for implementing basic or advanced consent mode, especially when Osano is installed directly on your website and not through GTM.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
CookieFirst CMP Consent State
You can use this template with the CookieFirst CMP to detect an individual user’s consent state and control tag execution in GTM. Useful for implementing consent-aware tagging when CookieYes is installed directly on your website.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
CookieYes CMP Consent State
You can use this template with the CookieYes CMP to detect an individual user’s consent state and control tag execution in GTM. Useful for implementing consent-aware tagging when CookieYes is installed directly on your website.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
Termly CMP Consent State
You can use this unofficial Termly CMP template with the Termly CMP to detect an individual user’s consent state and control tag firing in GTM. Ideal for enabling consent-aware tagging when Termly is installed directly on your website.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
Ketch CMP Consent State
Use this unofficial Ketch CMP variable template with the Ketch CMP to retrieve an individual user’s consent preferences and control GTM tag behavior. Ideal for setups where Ketch is installed directly on your website.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
Iubenda CMP Consent State
Google Tag Manager custom variable template that detects Iubenda consent states using purpose ID and regional fallbacks, with customizable output formatting.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
ConsentMo CMP Consent State
Google Tag Manager variable template to evaluate ConsentMo CMP consent state. Helps support Consent Mode setup and conditional tag firing based on user consent without native GTM integration.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template
ConsentManager.net CMP Consent State
A Google Tag Manager custom variable template to retrieve consent state data from the ConsentManager.net CMP. Supports fetching all or specific purpose consents and allows optional output transformation.
- TYPE:
- Web
- Submitted For Approval

- CATEGORY:
- Variable Template