Fix your broken Google Analytics setup
As user experience designers, we need to base our decisions on evidence and most of the behavioural data we have access to is found in Google Analytics. This is a hugely useful tool but before we use this data to provide actionable insights, it is our responsibility to ensure the data is accurate.
There are a number of common mistakes that we see again and again. This post aims to give you a troubleshooting guide to get started and make sure your analytics platform is providing you with data you can trust and use.
Are you gathering all the relevant data? Google Analytics tracks a lot of data out of the box but a few of the reports need some settings enabled before it will start collecting all the right data.
Your tracking code isn’t on every page
This is a basic requirement, but crucial. If any pages are missing the tracking code, not only will this data not be collected but it will ruin other metrics that track the user journey.
An easy way to check your site is by using a crawler, such as www.gachecker.com.
You haven’t enabled demographics tracking
Enabling demographics tracking on the account means you get access to demographic data such as the age and gender of your site visitors. This data comes from the third-party DoubleClick cookie, the one that allows Google to serve you targeted adverts for things you might be interested in.
By tracking what sites you have visited, Google makes an assumption about your age and gender that has a high degree of accuracy. This data is particularly useful if you are using AdWords to target ads on the Google Display Network as it uses the same categories, so you can explore how different demographics behave on the site and then target your advertising accordingly.
You haven’t enabled enhanced link attribution
If you want to track how visitors are using your site you need to understand how they navigate around it and what elements on the page they are using. By enabling enhanced link attribution you can see whether your users are clicking through to a page from the navigation bar or a call to action on the homepage. Essentially this allows you to view a heat map on pages that can be analysed alongside other reports and segments.
Note: This requires the links to have unique IDs.
You haven’t linked up your Google accounts
You may have noticed a lot of “not provided” entries in your organic search keyword reports. This can be mitigated by linking your Search Console account (what used to be Webmaster Tools) with Analytics.
This enables reports that show you how your organic search channel is performing including search queries, impressions, clicks, and position. Combining this with behaviour once on the site provides a valuable tool to be able to optimise the site for your key audiences. This is also true for your AdWords and AdSense accounts, so link any other accounts you have with your Analytics account.
You aren’t tracking site search
If your website has search functionality then this feature is crucial in tracking your user’s behaviour. It provides reports to monitor keywords and behaviour of those using the search function, allowing you to see what users are looking for.
This feature requires a search parameter to be specified, i.e. the URL has s=keyword. If the search can’t be set up with a search parameter, i.e. the URL has search/keyword, then you will have to monitor these keywords by using a search and replace filter to extract the search terms.
You haven’t enabled e-commerce reporting
A goal of many websites is to generate some form of revenue for the business. If this is the case then the e-commerce reports are great for you to dig deeper into the specifics of how your website is performing.
Is your data trustworthy? We analyse data and see the aggregated results, for example a huge spike in sessions on your homepage — great news! But is this due to a huge overnight increase in interest or is it because your intranet has been launched on a subdomain with the same URI? You probably don’t want to be the one who starts bragging about your marketing achievements based on erroneous data.
You haven’t configured the Referral Exclusion List correctly
This is particularly important if you have cross-domain tracking set up. Whenever someone arrives on your site from another source, Google counts that as a referral and triggers a new session. This makes sense if someone has arrived from a link on another site that is not yours.
This can cause problems with your data if that source is another site of yours, for example a third-party payment processor or a microsite. By adding these domains to the exclusion list Google knows not to trigger a new session for these visitors.
Note: Cross-domain tracking can be complex so should be carefully considered before implementation.
You haven’t set the correct time zone
This is a fairly basic requirement but it’s important to just make sure that the time zone matches your other Google accounts. This is especially important for AdWords campaigns.
You aren’t using three views for each property
This is extremely important for the accuracy of your data. Every property you are tracking should have three views:
- a Master view where reports are done,
- a Test view where new settings and goals are tested first to see if they correctly set up,
- and an Unfiltered view with just the raw data as a backup.
This last view is crucial because when filters are applied to a view, it irrevocably alters the data, so if a mistake is made it will ruin all your reporting data.
You haven’t excluded internal traffic
A filter should be used to exclude all internal traffic (including staging and developer). Internal visitors are likely to behave very differently to your external users and can skew your data, particularly conversion rates.
If you would like to track how internal users are using the site, then set up a new view with an include filter to just see internal traffic.
You haven’t excluded spam traffic
Depending on the amount of traffic on your site spam can account for anything from less than 1% of traffic to over half. Either way it is a good idea to filter it out because, much like internal traffic, they are not real users and so any data that includes spam can be skewed.
You haven’t prepended the hostname
Prepending the hostname adds the whole URL to the data which can help make your reports more readable. It is absolutely critical if you are tracking across different subdomains or domains. Without this filter it is impossible to distinguish between the different URIs of subdomains e.g. site.co.uk/ and sub.site.co.uk/ would be treated as the same page.
Are your reports clear and easy to analyse? By now you can be confident that your data is trustworthy but when it comes to looking at the data you can help avoid user error by tidying up the reports. In particular this prevents the artificial reduction of a page’s importance to visitors due to there being many entries for what is essentially the same page.
You are using the default page setting
If your site allows access to a page from two different URLs, e.g. xyz.com and xyz.com/index.php then Google suggests you add that index.php page path to the default page in view settings. However by adding that, Google appends the entry onto every single request URI in that view. This is intended to clean up the data, but in reality it makes it worse. This would be much better served by setting up redirects on the pages themselves, or if that’s not possible, a filter to remove the index.php page paths.
You haven’t excluded URL query parameters
URL query parameters can cause a huge duplication of content in your reports making it extremely difficult to measure the effectiveness of your pages. This setting allows you to specify which query parameters should be stripped out of the URL. Be careful to only exclude those that manipulate content within a page, e.g. sort filters, and not ones that provide unique content e.g. pagination.
You haven’t forced lowercase data
Google is case sensitive so /contact and /Contact would be counted as two different pages yet the user would see the same page. To combat this set up a filter on your account to force all URIs, search terms, and campaign dimensions into lowercase format.
You haven’t appended or removed the slash on the request URI
The trailing slash on URI’s should be added or removed if you notice duplicate rows due to the presence of a slash.
Note: this should always be the final filter.
That concludes our list of troubleshooting tips — I hope you’ve found them useful. It’s clear that there are many ways your data might be tripping you up, but with a bit of time and effort this can easily be rectified.
Nick wrote this story to share knowledge and to help nurture the design community. All articles published on uxdesign.cc follow that same philosophy.