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.
Before reading further, make sure to verify whether you have a Universal Analytics (UA) property or a Google Analytics 4 (GA4) property so that you can follow the correct instructions, as steps might differ between both property types.
Not sure which Google Analytics property type you have? Read about the differences here: Google Analytics 4 Versus Universal Analytics
Step 1: Enable User Tracking in MonsterInsights
The first step is quite easy. You’ll need to navigate to Insights » Settings » eCommerce in your WordPress dashboard.
From here, you can check the Enable User ID tracking toggle to turn it on. The panel will auto-save your new setting as soon as the toggle is adjusted, but you can also click on Save Changes.
Step 2: Enable User Tracking in Google Analytics
Google Analytics 4
If you have a GA4 property, you’ll see that tracking is automatically set to utilize a supplied User ID by default at Admin » Reporting Identity.
You’ll see two options Blended and Observed.
The Blended option (recommended) will be selected by default.
This means your GA4 property will try to use User ID if it’s available. If there isn’t any User ID to use, client ID will be used as a fallback.
To see your data, go to Explore and create a User Explorer custom exploration.
If you have a UA property, after enabling User ID Tracking in MonsterInsights, you will also need to configure your UA property to enable User-ID tracking in Google Analytics.
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 centre column to expand the submenu, and click the User-ID link that appears below.
You’ll be taken to the first step of creating a User-ID view. Make sure to read through the User-ID policy and agree by toggling the I agree to the User-ID Policy option to On and click on the Next step button.
In the second step, you don’t need to do anything but click Next Step again (the Session Unification will be On by default).
In the third step, click the Create button to create the User-ID view.
Next, you will create a new reporting view. The first step will be to fill out the Reporting View Name.
We recommend including “User-ID” in the name so it’s easy to remember which view has User-ID tracking enabled.
Then, turn on the Show User-ID Reports option for this view and then click the Create View button.
You’ll see a brief success message and now be able to access your new User-ID view
There will not be any data in the User-ID view.
It can now take 24 hours for data to display in the new view. It will not contain data from the past, however, data will start being collected now and moving forward.
While in your User-ID view, 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 assigned WordPress User ID. You can click on the WordPress User ID number 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 at 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.