Advice and answers from the UserGuiding Team
Users
Engagement
Settings
Enabling User Identification with Google Tag Manager
Learn how to set up User Identification through your GTM account.

Overview

By enabling User Identification, you will send unique user IDs for your end users dynamically to have persisted user data for your end-users at UserGuiding.

 

Implementing User Identification requires access to your web platform or site's source code which is one of the three environments you will take specific actions to succeed.


1. panel.userguiding.com

 

 

2. Google Tag Manager

Login to your Google Tag Manager account, where you'll use the identify snippet copied from UserGuiding dashboard.

 

Next, you will create a trigger, a variable, and a tag in your GTM account.

 

We will use example variables to demonstrate, but please note that these could be different in your implementation. You can name and configure these variables as you need.

 

a. Create a Trigger

Here, you should create a Custom Event Trigger.

 

The function of this custom event trigger is to tell the tag (having the identify snippet) to fire when the specified event is detected.


Important: Inside your web platform's source code, you should have a code to push the trigger's custom event into the data layer.

 

You can see in the image below that we created a custom event trigger called "identifyUser".

 

This way, the Tag Manager can detect identifyUser as a custom event value and fire the tag.

 

 

b. Create a Variable

You should create a Data Layer Variable.

 

Each user ID you want to send to UserGuiding is an individual value. Thus, the Data Layer Variable you create will be the placeholder for these values.

 

Important: Inside your web platform's source code, you should push data (user IDs) to the data layer to set values for the data layer variable. Learn more.

 

You can see in the image below that we created a variable named "userId".

 

The value will be set when data is pushed to the data layer.

 

 

c. Create a Tag

You should create a Custom HTML tag. This is where you will use the identify snippet copied from panel.userguiding.com and your configurations so far.

 

See the below image depicting a tag named "UserGuiding - User Identification".

 

With this tag, we can send user IDs to UserGuiding via GTM.

 

 

  • After adding your Tag, save it and publish changes in your GTM account. To ensure your tag configurations function as expected, you can preview and debug containers at GTM.
  • Finally, return to your UserGuiding panel (installation section) and click Enable Identification button at the bottom left. Then, click Publish Changes button on the top-right.

3. Your Source Code:

[actions below are previously mentioned]

 

Implementing User Identification requires access to your platform's source code. We have already shared two important notes with you, as you might recall.

 

Important Note 1: Inside your web platform's source code, you should have a code to push the custom event into the Data Layer.

 

Important Note 2: Inside your web platform's source code, you should push data (user IDs) to the data layer to set values for the data layer variable. Learn more.

 

User Identification Enabled

Once it is enabled and active, you will be able to access your API Key (API Access Token) in the section shown below:

 

 

You can use our API Documentation to see how to utilize the User API. We recommend you get support from your development team and use an API Development Environment to access this data. Postman is an excellent alternative for this task.

Testing if User IDs Are Being Sent Successfully

You can use the User API to check if the user IDs you sent to UserGuiding have arrived.

 

Alternatively, as a current and one of the identified users (a unique ID is sent for you), you can access one of your platform pages where UserGuiding's container code is installed.

Open the Troubleshooter and view Current User Information to find your unique ID.

 

As you can see from the image below, User Identification is completed for the current user because a unique ID is assigned to them. Their unique User ID is 10149.

 

Did this answer your question?