How to Track Google Analytics Demographics When Using Universal Analytics

How to Track Google Analytics Demographics

If you’ve been tracking your website’s analytics using Google’s Universal Analytics code, you may have noticed that you’re unable to track user demographics.

Fortunately, with a few adjustments, we can set up Google Analytics to track user demographics while still reaping the benefits of using the Universal Analytics code.

First, if you haven’t been tracking user demographics on your site in the past, let’s take a look at some of the data that is collected once you have activated the demographics code. Age, gender and interests are tracked once you’ve activated the demographics code.

The benefit of knowing not only how many visitors are coming to your website, but who those website visitors are can be very beneficial. You can also access this data in custom reports and segmentation, allowing you to view how behaviour changes between the various types of visitors to your website.

For example, do females under 30 years old interested in fashion convert more frequently than males under 30 years old who are interested in technology. Knowing this information gives you an edge that you didn’t have before.

Also read: Getting Started with Google Tag Manager

How to Track Google Analytics Demographics

How to Track Google Analytics Demographics

Gaining access to demographic statistics is fairly straight forward. If you’re currently using the Universal analytics code, you’ll need to create a new analytics property using the Classic Analytics code. I’d recommend naming the property to indicate that is tracking demographics, as to not confuse the new property with the original property. Be sure to enable “Turn on Advertiser Support” when creating the property.

The newly generated classic analytics code should like like this:

  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-XXXXXXXX-7']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'stats.g.doubleclick.net/dc.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();

Copy and paste the code underneath the existing Universal Analytics code on your website. Your exiting Universal Analytics code should be found in the < head > or < footer > of your site.

If you’re unsure, look for the code similar to this:

(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','//www.google-analytics.com/analytics.js','ga');

      ga('create', 'UA-XXXXXXXX-6', 'your-site.com');
      ga('send', 'pageview');

Once you’ve added both codes to your website, you may need to visit the “Demographics” tab from within the newly created analytics property and verify that the code has been added correctly. You should begin to see data shortly thereafter, usually within 24 hours. Hopefully you can use the newly gathered data to your benefit. If you have any questions about setting up Universal and Classic analytics to run simultaneously on your website, please leave your questions in the comments box below.

Author: Dylan Dunlop

Tribble Agency is a digital marketing company that specializes in backlink services services to help increase authority with link building methods that have a direct impact on directing potential visitors.