Skip to content

CardinalPath/gtm-template-ga-property-id-variable

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cardinal Path

Courtesy of Merkle | Cardinal Path - http://cardinalpath.com/

GTM Template Variable: Dynamic Measurement ID

Introduction

It is a common practice to send test data to an alternate Property ID (UA-XXXXXX-01) so your development hits do not populate your production reporting. Many will use nested tables for this but it can be a messy setup if trying to accommodate all types of testing.

This variables will allow you to easily toggle based on Environment, whether you are in Debug Mode, or accessing a development domain.

Variable Configuration

GTM Variable

  1. Production UAID should be populated with your production Measurement ID
  2. Development UAID should be populated with your development Measurement ID
  3. Populate the non production URL in the "URL Pattern for Developement Domains" field. You can omit the "http://" portion. Add a second row if you have a second develoment domain. Using a value such as "dev" will match any URL that contains "dev" within the URL. Regular Expressions are not supported.

About

Dynamic Property ID for Google Analytics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages