I am trying to figure out why the custom dimension I created with a User-level scope isn't collecting the right data.

I have set up two custom dimensions:

Job - User scope Job - Hit scope

According to my understanding of how these dimension scopes work, I should really only need the "User scope", since the data I'm tracking is specific to the user, not the page view (Hit) or even the session. I set up dimensions for both User and Hit scopes because this is the first time I've done something like this and I wanted to be robust in my testing. Ultimately, I expected the exact same data from both scopes, an expectation that seems to be supported by Google's help page on the topic:

Note that although this same functionality could be achieved with hit or session-level scope, user-level scope provides the most convenient solution with the least amount of code.

However, the data I am getting is very different. There are 3 job options the Drupal user can select for their profile. I have created 6 test accounts, and given each job to two of the test accounts. The data I am getting looks something like this (the numbers are the amount of pageviews):

User Scope
Manager: 191
Administrator: 0
Developer: 0

Hit Scope
Manager: 63 Administrator: 56 Developer: 35

When doing this testing, I kept track carefully of what pages I visited with each user. The Hit scope data is definitely correct.

Why didn't the user scope data work correctly?

One thought is that since I used the same browser for these tests, GA considered to think I was the same user even though I logged into different accounts. So perhaps all the hit-level data, when added together along with some additional page views from my admin account, would equal the 191 value I get for Manager. Another thing that supports this is that I seem to have collected additional Manager page views on subsequent days, even though I never logged back in with one of those test accounts. So that makes it seem even more likely that my admin account was triggering some additional "Manager" page views incorrectly.

Does anyone else have experience with these kinds of issues, or see what conceptual mistake I have made regarding scopes?

  • Questions about Google Analytics do much better at Webmasters.
    – Al E.
    Jun 8, 2015 at 21:39

2 Answers 2


Way you should do testing:

  • in different browsers
  • same browser, removing installed cookies
  • same browser, editing installed cookies (lot of browser extensions can do that)

A custom dimension at user level would be set on a persistent cookie, right? So even if you log out and simply login (no new registration) means there's no cookie overwriting.

So, I suggest to simply edit your persistent cookie and put it as Administrator/Developer, then you see reporting. If it works, consider changing the way the persistent cookie is installed.


In Google Analytics, a 'User' is defined as a unique device/browser combination. User-scoped dimensions are applied to every hit for that user.

User-scoped dimensions will also continue to be applied to that account even if they are no longer included on the hit level - thus logging out wouldn't effect the presence of a user-scoped dimension.

Because you used the same browser for these tests, the final setting you used would have overwritten the previous settings. For this reason, setting a scope to 'User' should be reserved for variables you expect never to change for a user.

If you expect users to occasionally change this setting, there is no harm in setting it as hit/session-scoped. An instance where 'User' scope makes sense is gender, which you would expect to remain constant in all cases (for most websites). It's essentially a trade-off - do you want this setting to reflect the user's chosen setting at all times, or is it more important to you that the dimension persists even when the user logs out?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.