Upcoming LunaMetrics Seminars
Los Angeles - Anaheim, Sep 8-12 Washington DC, Sep 22-26 Boston, Oct 6-10 Chicago, Oct 20-24

How to Access Custom Dimensions in Google Analytics

“Give it to me. NOW!”

- Veruca Salt, Willy Wonka and the Chocolate Factory

If you are using Universal Analytics you may have heard something about Custom Dimensions. They’re the next evolution of Custom Variables. Regular Google Analytics users get 20 of them, while Google Analytics Premium users get a whopping 200 of them.

I’m not going to cover here how to implement them. It’s pretty easy though. Here’s the Google Analytics documentation on the implementation.

What should you put in them? I’m not going to cover that in this post either but if you had trouble filing up 5 variables, then you might get overwhelmed by 20 or 200 dimensions. Here are some old ideas for custom variables. Most of those translate perfectly into Custom Dimensions.

What I AM going to cover is how to see these custom dimensions in your data. In the past few months we have talked to multiple people who implemented Custom Dimensions but couldn’t figure out how to see the data. I am fairly certain that at some point in the future we will see much better standard reports that let you access your custom dimensions. If Murphy’s Law works, then by writing this blog post, this possible new report will be announced and released within a week. Let’s call using Murphy’s Law to our advantage an ulterior motive for this post.

I want my Golden Goose… Now.

I look forward to the future comments by people saying “What do you mean? They are in the standard reports? You’re stupid!” who obviously have no reading comprehension or ability to see the timestamp on a post. THIS IS A TEMPORARY SOLUTION FUTURE DWELLER. I PRAY THIS IS WRONG IN YOUR FUTURE OF FLYING CARS AND TANG.

But if you want to see them TODAY you need to use either Custom Reports or Dashboards. If you look in the Custom section of the standard reports you will find but crickets.


Necessary Tangent: Loves Data, another GACP, did a great and some would say famous case study on Universal Analytics by tracking the use of their coffee machine in their office by using RFID keys to grab and track data that WASN’T web data. If you haven’t seen it, check the post and video out here: http://analytics.blogspot.com/2013/04/universal-analytics-business.html

Building off their coffee machine analogy we experimented tracking what our employees made with our own Latte Lounge, looking at not just consumption but WHAT drink they made. The Latte Lounge has many options. Regular coffee, flavored coffee, cappuccinos, lattes, mochas, even just hot water. We tracked the drink as a page view, and the options chosen as custom dimensions. We defined the various options our machine offered from bean, to the flavor and size, as well as the drinker.


To put them into a Custom Report or Dashboard you need to know these names. Where custom variables have slots these are dimensions that you are defining, so you have to search for them by name. Like “Drink” or “Member Status”.


That lets us look at our custom dimensions relative to the metrics. So we can see that Jim Gianoglio drinks the most coffee in the office. Given that a few of my pageviews were actually test hits, he drinks more by a significant margin.


Or we can see that the Jim prefers to order Vanilla Hazelnut Cafe Latte’s.


In addition to Custom Reports they are available in Dashboards as well. Here’s a dashboard showing different breakdowns in what drinks people got, what beans they chose, what flavor choice they made.


Interestingly the drink and flavor combination report showed that by far the most ordered drink in the office was a medium strength unflavored coffee. This is about the most boring flavor you can get from such a fancy machine. The second place drink? Vanilla Hazelnut Cafe Latte’s almost solely thanks to Jim.

Just like in Custom Reports you have to choose the dimensions by their assigned name, not their slot.


Hopefully this gives you some more encouragement to get to using your Custom Dimensions sooner rather than later. What data can you capture and put into Custom Dimensions on your website that you can combine into your own interesting reports and dashboards to gain insight? If we tracked a coffee machine for a couple of weeks and determined that it’s pretty much just Jim that is drinking all the vanilla hazelnut syrup, shouldn’t you be able to find some sort of more valuable insight in your own data?


Thanks again to Loves Data for the inspiration for our example. And to Jim for his consistent coffee order.

Sayf Sharif

About Sayf Sharif

Sayf Sharif is a Web Analyst, and expert in Usability and UX, who has worked with businesses large and small to maximize their online presence since the beginning of the Web, winning numerous awards along the way. Sayf has studied human tool use from the stone age (he went to graduate school for Archaeology) to the information age (he started programing on his father’s TRS-80), and is always interested in what goals people wish to accomplish using their tools, and how successful that experience was.


13 Responses to “How to Access Custom Dimensions in Google Analytics”

Mark says:

I actually wrote a fairly detailed walkthrough for site owners on how to go about setting up custom metrics and dimensions in Analytics that might be of use to people here aberrant.me/tracking-custom-dimensions-metrics-in-universal-analytics/

Sandip Borde says:

Through Code(C++) how we can access custom dimension?Please Help.

Sayf Sharif Sayf Sharif says:

If you mean how could you send this data into GA from a C++ application then you could use the Measurement Protocol: https://developers.google.com/analytics/devguides/collection/protocol/v1/

Dear Sayf of the passed,

Thank you for this post. I was going to bookmark this and come back and comment when the custom dims. were made available in standard reports. -Too much work. Your understanding of the immutability of time is far greater than your average internet bear. Thanks!

Sayf Sharif Sayf Sharif says:

Thank you Future Trevor!

What’s the value of Twitter stock in the future?

ego says:

Please help me, master! :)
I created two custom dimensions. On button click listener I added event:
ga(‘send’, {
‘hitType’: ‘event’,
‘eventCategory’: ‘SomeCategory’,
‘eventAction’: ‘SomeAction’,
‘eventLabel’: {‘dimension1’:’value1′,’dimension2’:’value2′}’

Now in QueryExplorer I see my evens. In Label column I see [object Object]
But if I add in dimention list one (or both) of my custom dimention I have no result.
What’s wrong?
PS: Sory for my english :)

Sayf Sharif Sayf Sharif says:

Well, when you pass {‘dimension1’:’value1′,’dimension2’:’value2′} you’ve just passed an object, so that’s why it reads as one. That synax is basically an object constructor. It’s interesting that it reads in GA as [object Object] like a javascript object, but obviously that’s not helpful to you.

ga(‘send’, {
‘hitType’: ‘event’,
‘eventCategory’: ‘SomeCategory’,
‘eventAction’: ‘SomeAction’,
‘eventLabel’: ‘SomeLabel’,
‘dimension1′: ‘My First Custom Dimension Value’,
‘dimension2′: ‘My Second Custom Dimension Value’

If for some reason you want to send those dimensions in the Label as well you should just concatenate a variable with the values prior to the ga(send and then pass that variable like:

var firstDimension = ‘My First Custom Dimension Value’;
var secondDimension = ‘My Second Custom Dimension Value’;
var myLabel = firstDimension + secondDimension;
ga(‘send’, {
‘hitType’: ‘event’,
‘eventCategory’: ‘SomeCategory’,
‘eventAction’: ‘SomeAction’,
‘eventLabel’: myLabel,
‘dimension1′: firstDimension,
‘dimension2′: secondDimension

Sharmi says:


I am sending the custom metrics value to the google analytics. while i check in the plugin of google chrome the values are perfect. But while I check in the reports, its showing the values double.. Why its happening?? Any solution you can suggest for this??

Sayf Sharif Sayf Sharif says:

Sharmi, I’m not sure. Something seems to be going wrong, are you sure you’re not passing it twice? Unfortunately without actually seeing the code myself I don’t think I have anything I can add to help you.

neha says:

I am trying to implement a custom report with custom dimension as SchoolID. We have different schools logging into our site. So, we need to track their page views based on those SchoolIDs and also do event tracking.
I am using following code:
ga(‘send’, ‘pageview’,{‘dimension1′: ’19951′});

Also, I have created a custom dimension with index 1 as SchoolID and is active.
I can see the data being passed but I can’t see it in my report..
Any reasons why this could not be working? SchoolID column is blank in my report.


Sayf Sharif Sayf Sharif says:


First, just to confirm that the code is firing, and you’re seeing the pageview and dimension get passed via something like the Chrome GA Debugger plugin? The code above has the non-standard single quotes which would error the code, so I don’t want to assume that it’s working, and not a syntax issue.

Second, when you say you can’t see it in your report, do you mean you can’t find the custom dimension by selecting from the secondary dimension drop down on the All Pages report, for instance? If not, confirm that the dimension is set up in the correct property/view that you are in.

Third, but assuming the code is working, and you are in the right place, and the dimension is set up in your custom definitions in the property you are in, and you can see the dimension, but there is no data, and you are looking at the right time span, and not filtering that traffic out in some way (like maybe you’re filtering out your local ip and so it is there ,but filtered out, etc)… then I am not sure.

1) Confirm that the code is actually firing.
2) Make sure that your’e in the right view and property where the custom dimension is set up correctly.
3) look for the pageview firing in real time reports
4) make sure your’e not filtering out your traffic from a view, use an unfiltered profile
5) in the standard reports make sure you’re in the current right date range, without segments.

harrrry says:


Sir, your post helped me alot.
I am trying to send custom dimension on click event on button like this:
val[5] contains some string.
I have created 1 customized table.
But event gets generated when i click on button but nothing is coming in custom report table.
What should i do now?
And is it necessary to use ‘set’ command before sending custom dimension?
If is where to place it?

Thanks in advance,

Sayf Sharif Sayf Sharif says:

Not sure Harry. Assuming your code is correct, are you seeing the event fire from the window to Google Analytics?

You only need to use the set command, if you want those values to be sent with every other hit from the page. Including them on an event itself should work fine.

If you are seeing the event send a hit (via a Chrome tool like GA Debugger in the console) then I would confirm you have the custom dimensions and metrics properly set up in your admin section of the property under Custom Definitions. They need to be correctly set there.

If the code is correct, and sending data to the right GA account/property, and you are not filtering out your own IP address on that view, and the custom definitions are set up correctly, and the custom report/table is set up correctly, then you should see it.

There are lots of places you could be having problems. Follow the trail from one end to the other.

Leave a Reply