December 4, 2014 ↘︎

Setting up Google Universal Analytics User ID tracking with Adobe Dynamic Tag Management (DTM).

Loading the Elevenlabs Text to Speech AudioNative Player...

One major advantage of Universal Analytics is the ability to analyse groups of sessions across multiple browsers and devices. This is achieved using a unique, persistent, and non personally identifiable ID string to represent a user, allowing for a more accurate user count.

Traditionally, unique visitors rely solely on a cookie created by the browser. When a user revisits the site, the analytics platform checks the cookies and determines whether or not a Visitor ID has been set. This method runs into issues when the same person is using multiple browsers and/or devices, as each browser/device will create a new visitor ID. To overcome this issue, after a user signs in on your site, the User ID feature will send the unique user ID from your website to Universal Analytics.

These additional reports are also made available:

  • User ID Coverage Report –shows the split between visits with an assigned user ID and those without.
  • Device Overlap Report –shows the percentage of users that use a combination of devices.
  • Device Pathing –shows the device used for a sequence of sessions.
  • Device Acquisition Report –helps you understand the value of users on a certain device, based on the device first used to open or interact with your content.

How do I implement Universal Analytics User ID tracking in Adobe DTM?

1) Create a data element that captures your Unique User ID.

The critical requirement in setting up the User ID feature of Universal Analytics is that you expose a unique and non personally identifiable ID string representing a specific user to DTM. This ID might come from your CRM or other customer database.

The best way to expose this data is to pass it to your website’s cookie when the user has logged on, and up until the point they sign out. If exposed via a cookie, it is just a matter of creating a new cookie type data element and putting in the cookie name that represents the User ID value.

2) Add the Universal Analytics tool.

Once you’ve set up your data element to capture the User ID value, add Universal Analytics as a tool within your DTM property if you haven’t already.

It’s important to take into account the tracker name chosen, as depending on which option is selected, there will be slight differences in how you implement the code. If you have only one GA implementation across your site, and all GA tracking is contained within DTM, I recommend selecting the GA Default Name option. This will simplify any additional GA tracking implemented within DTM’s custom script sections. Both the DTM Generated Name and Specify Name options will require you to define the tracker name on any additional GA calls within your custom GA scripts in DTM.

3) Add the User ID script.

Under the Customise Page Code section of the Universal Analytics Tool settings, open the editor and add the following script;

if (_satellite.getVar('User ID Data Element Name')){
 ga('set', '&uid', _satellite.getVar('User ID Data Element Name'));
 }

To set the user ID replace ‘User ID Data Element Name’ with the name you gave your User ID data element.

4) Test script.

In each GA request, where the user is signed in, the script should send the parameter and uid of the value of the data element. Upon the user signing out no value should be sent. The easiest way to test is with the Google Tag Assistant plug-in for Chrome where you should see the User ID being sent as below:

Validating User ID tracking in Google Tag Assistant

5) Activate the User ID feature within Universal Analytics.

Once everything is set up, and you’ve validated that the correct data is being sent, you can activate the feature within Google Universal Analytics. Please refer to the following Google Analytics support page for help on how to activate this.

 

Welcome to a new world of multi-channel attribution.

Once all these steps have been completed, publish the changes in DTM and you will start to see unique users based on the ID being tracked within Google Universal Analytics. Finally, you will be able to see users’ behaviour across multiple devices to help in understanding how your users interact with your site across these multiple devices.

Be sure to subscribe to our blog as we continue to explore implementing more features of Google Analytics in DTM and check out other related posts including Setting up enhanced link tracking for GA in DTM.

DB logo
DB logo
DB logo