How to Set Up User Tracking in Google Analytics
Want your stats to identify logged-in users by their WordPress user IDs? It’s easy with MonsterInsights. In this guide, we’ll show you how to enable user tracking in MonsterInsights and in Google Analytics, so you can start tracking individual logged-in users.
Step 1: Enable User Tracking in MonsterInsights
The first step is quite easy. The eCommerce Addon will need to be active. Then, you’ll need to navigate to Insights » Settings» eCommerce in your WordPress dashboard.
From here, you can check the Enable User ID tracking toggle. The panel will auto-save your new setting as soon as the toggle is adjusted.
Step 2: Enable User Tracking in Google Analytics
After enabling user tracking on the Demographics tab of the Tracking section of the MonsterInsights settings, you will need to enable this feature and create a new UserID view in Google Analytics in order to make use of this feature.
You’ll need to log in to your Google Analytics account and select the website you’d like to enable user tracking for.
Then, click Admin.
Now click the Tracking Info link in the center column to expand the submenu, and click the User-ID link that appears below.
On the next page, you’ll have to click the Off switch to On and click the Next Step button to agree to the User-ID policy.
In step 2, you don’t need to do anything but click Next Step again.
In step 3, just click the Create button to create the UserID view.
Next, you will be taken to this screen where you will have to enter a Reporting View Name (we recommend including UserID in the name so it’s easy to remember which view has UserID tracking enabled).
Then, turn on the Show User-ID Reports option for this view.
Finally, you can scroll down and click the Create View button.
You’ll see a brief success message. Then, click the Google Analytics logo at the top of the page.
You can now access your new User-ID view.
Then, just click on Audience » User Explorer in the left menu to see your user data. You’ll see that each user is now listed by their user ID in WordPress.
You can click on the User ID to see more detailed info on each user.
Wondering how to tell which WordPress user belongs to which ID? To find out, just go to your WordPress dashboard and click on Users » All Users.
Then, hover your cursor over the user you want to find the ID for. You’ll see a URL appear in the bottom of your browser. In the middle of the URL, it will say “user_id=”. The number after that is the user’s ID number.
You can click the Edit link under the username to make sure. You’ll see the user ID in the web address on the edit page.
That’s it! Now you can track each WordPress user who has an account on your site.
Want to track even more data? Check out our guide on how to get started with the MonsterInsights eCommerce addon.