Mobile app version of vmapp.org
Login or Join
Welton855

: No data appearing in custom Google Analytics report using a custom dimension I want to send a custom dimension to google analytics to use in a custom report as per: In some cases, you

@Welton855

Posted in: #CustomDimensions #GoogleAnalytics

I want to send a custom dimension to google analytics to use in a custom report as per:


In some cases, you might want to send a custom dimension or metric with all the hits on a given page (or for the lifetime of the tracker object). In this case, you can set the custom dimension or metrics using the set command: ga('set', 'dimension5', 'custom data');


This is my script:

(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', 'TRACKING-CODE', 'auto');
ga('set', 'dimension5', 'some value here');
ga('send', 'pageview');


My custom report looks like this:


But I'm not getting any data e.g. some value here. Am I doing something wrong?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Welton855

1 Comments

Sorted by latest first Latest Oldest Best

 

@Berumen354

You don't have to use a Custom Variable, in Analytics go to Admin (in the bottom of the sidebar menu) > Custom definitions > Custom dimensions and add dimension5, then you will have dimension5 available to use it as a dimension in your custom report.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme