I want to track a simple subscription product with Google Analytics and need to determine how to best track (a) User State, and (b) Subscription conversion rate.

At any given time, a user can be a:

  1. Guest: Logged out
  2. Member: Logged in, but not on a paid subscription
  3. Subscriber: On a paid subscription

I plan to track this using a session-level Custom Dimension ("User State"), whose value changes when the user moves from one category to another.

Additionally, non-Subscribers can purchase a subscription at any point. This will be registered through an event ("Purchased Plan") tied to a Goal.

My questions are:

  1. Should I use a hit-level, session-level or user-level custom dimension for User State?
  2. If using a session-level or user-level dimension, how do I deal with the case of users logging out mid-session and their entire activity being classified as "Guest"? For example, a "Subscriber" views 20 pages, then logs out, which immediately puts the entirety of that session as a "Guest" session.
  3. When I look at the "Purchased Plan" conversion rate, how can I exclude existing subscribers from the denominator in order to get a clean rate?

For this last case, I thought of using an advanced segment configured to "Include Users with User Type = Guest or Member" and then look at the conversion rate for this segment.

But users that purchase a subscription are immediately changed into User State = Subscriber, so the entirety of their activity (in a session-level or user-level) scoped custom dimension would be classified as such, rendering my advanced segment worthless (i.e. the user's activity will not be present in that segment).

The other option would be to set User State to hit-level scope instead, so that I can discriminate the user's activity before and after the subscription event.

How can I deal with this situation? Any help will be greatly appreciated.

2 Answers 2


It really boils down to the queries you expect to make.

If you use hit-scope, you will be able to create segments that differentiate actions that take place within a session. So a user could start as a guest, then log in to become a Member, the pay for the subscription to become a Subscriber, and finally log out to become a Guest again. With a hit-scoped dimension you can query all of these, but the queries can become quite complex.

If you use session-scope, then the last value you sent into the custom dimension will apply for the entire session. Thus you'll lose the granularity. The good thing about session-scope is that you only need to send it once. It will automatically apply to all hits of the session.

User-scope is like session-scope, but it will apply from the first time it is set for as long as the user has the same client ID.

How I would approach this is to look at the three levels. Member and Subscription are clearly scoped to the user, since if you are in one, you are in that until you upgrade, right?

Guest on the other hand tells you nothing about the user level. They could be a Subscriber but they just haven't logged in.

So here's how I would track it:

1) Do not track Guest at all. You can query for Guest by creating a segment for all sessions where the User State custom dimension does not contain Member|Subscriber.

2) Track Member and Subscriber as User-scoped dimensions.

3) Track Login and Logout as events, and send the current user state as an Event Label or a hit-scoped custom dimension.

With these three you will be able to:

  • Track sessions where the user didn't log in (exclude sessions with Event Category = login), and you can also combine it with the user-scoped dimensions to see how often members and subscribers browse the site without logging in.

  • Track member and subscriber traffic also on sessions where they didn't login (thanks to user-scoped dimension)

  • Track sessions where the user logged in as member (include sessions where Event Category is Login and Event Label is member), but the state is subscriber. This means that these sessions were the users upgraded their subscription.

And so on.


  • Thanks for the really detailed answer @Simo Ahava! This is really helpful. I'll follow up with another answer in this thread that puts your approach and some other thoughts I had together.
    – Ralph
    Jun 25, 2016 at 0:15

This answer builds on the excellent answer by @Simo Ahava and an approach I posted to an external discussion (Advertiser Community Thread).

Quick background:

When users browse under each state ("Guest", "Member" or "Subscriber"), they get an entirely different experience, so it's important to discriminate activity between states during a session. Hence my initial apprehension towards relying solely on session or user-scoped custom dimensions.

I also have access to GA data in BigQuery, so tracking user state at the hit-level will be valuable for more granular analysis.

Revised tracking approach:

I can set two custom dimensions:

  1. User State (user-scope): Value can be "Member" or "Subscriber" and is never reset when the user logs out. I like Simo's idea of never setting "Guest" to avoid users getting re-classified upon logout. Subscribers can always downgrade and get classified as "Member", but I guess that's fine.

  2. Page State (hit-scope): Value can be "Guest", "Member" or "Subscriber" and dimension is sent with every page and event hit.

I will also send events for "Registered", "Logged In", "Purchased Plan" and "Logged Out". I'm already using the Event Label in the Registered and Logged In events to indicate the type of authentication (Site Account, Facebook, etc).

Using the Page State dimension, I should be able to create advanced segments that help answer Simo's questions, plus:

For any given period of time...

  1. What was the conversion rate for member sessions? (Include sessions with Page State = Member and Event Action = Purchased Plan)
  2. How many subscribers browsed the site logged out and never logged in? (Include sessions with User State = Subscriber and Page State = Guest and Event Action != Logged In or Registered)
  3. How many sessions where the user logged in as member but state is subscriber? (Include sessions with User State = Subscriber, and Sequence of Page State = "Member" followed by Event Action "Logged In")
  4. What was the breakdown between "Member" and "Subscriber" pageviews for sessions in which the user purchased a plan? (Maybe with a custom repor, or in Big Query looking at sessions that had the "Purchased Plan" event and counting pageviews with Page State = Member versus Page State = Subscriber)

Are there any drawbacks to this approach?

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.