Setting up a Site ID variable
We recommend creating a Site ID variable that automatically sends traffic to your sandbox dashboard when using GTM’s preview mode. This helps keep your production dashboard free of testing data.
Prerequisites
All you need to proceed is knowledge of:
- Your Parse.ly Site ID(s)
- Your Sandbox Site ID
- Usually in the form of
sandbox.sld.tld
e.g.,sandbox.example.com
- If you have multiple production Site IDs, your sandbox may take the form
sandbox.publisher-name
e.g.,sandbox.acme-inc
- Usually in the form of
Instructions
- Click the Configure button in the Built-In Variables sections on the Variables tab and select the checkbox beside Debug Mode.
- Create a User-Defined variable of Lookup Table type with {{Debug Mode}} as the input variable. Add one line specifying when the Input is
true
the output is your sandbox site ID. You can call the variable parsely site id to use it later. - Set the Default Value to your production Site ID.
- Use this variable in the Parse.ly Site ID field in the tracker tag.
![Google Tag Manager, variable configuration screen showing an example Site ID variable.](https://docs.parse.ly/wp-content/uploads/sites/5/2024/05/SCR-20240514-nbnw.png?w=1024)
Next Step
With your variable set up, you may now add it to your Parse.ly tracker for your web or AMP container.
Last updated: August 15, 2024