What’s the primary purpose of Google Analytics? To track, report and measure the activity that happens on your website, right?
Of course, tracking, reporting, and measuring the activities that happen on your website all require you placing some code on your website. You can’t get very far in analytics without tagging your site.
What’s a tag? Tags are those little bits of code your analytics tool providers or advertising platforms ask you to place on your website so that you can send data back to their servers.
From a Google Analytics perspective, making sure you install your tags the right way, and that those tags are in the right places, is critical to the data quality in your Google Analytics reports.
Better tagging = Better data = Better decision making
So how do you ensure that you’re using the right tags and that you’re installing your tags in the right places to get the data you need? Well, that’s we’re going to cover in this guide.
And because you asked for it!
I’ve also included a Google Analytics Tagging checklist that you can use along with this guide.Download
How to use this guide and checklist
You can download our Google Analytics Tagging checklist and save it to your desktop. Or you can print it out our checklist and use it to help you audit and upgrade your Google Analytics tagging.
This guide consists of three sections, basic tagging, advanced tagging, and exceptional tagging.
The basic steps, which are outlined in this guide, will help you check to make sure your Google Analytics tags are up to date and in the right places on your website.
The advanced and exceptional steps in this guide will be available exclusively to our Analytics Course students. To access the advanced portions of our guide as they are released, join us inside Analytics Course.
Ready to start checking your tags, and improve your tracking plan? Let’s do it!
Basic Google Analytics Tagging Steps
☐ Step #1: Review the tags Google has provided to you
You can find the latest version of your Google Analytics tracking code in the admin area of your GA account. The tracking code Google provides you for your site is located in your Tracking Info menu.
Pro tip: Make sure you keep your site up to date with the latest version of the Analytics tracking code. Keeping your Analytics tracking tags up to date helps ensure that your data collection continues to work with all of Google Analytics latest features.
gtag.js vs. analytics.js
In October of 2017, Google updated the analytics tracking code from analytics.js to gtag.js. So, if your site is still tagged with analytics.js, you may want to update your code.
GTM Tracking templates and automatic updates
However, if you installed your tracking code using Google Tag Manager’s (GTM) Universal Analytics tag template, you don’t need to worry about updating your code. The GTM tracking template automatically updates to work with Google Analytics latest features.
(If you need help figuring out how, or where to put the Google Analytics tracking tag on your website, check out our Google Analytics account setup guide.)
In our next step, we’ll look at how to check which version of the Analytics tracking code is currently collecting data on your website.
☐ Step #2: Check to make sure your Google Analytics tracking code is valid
You can use the Google Chrome extension Tag Assistant to do a quick check of your website’s primary tracking tags.
☐ Install Tag assistant
☐ Review the tags on your site
Tag Assistant will show you which version(s) of the Analytics tracking code your site is currently using.
If you’re using GTM, you should see your GTM tag in your Tag Assistant report.
☐ Do you have any errors in your tags?
Tag Assistant can also help you find problems or errors in your tags.
☐ Is your site tagged with a tracking code that doesn’t belong to your account?
Using Tag Assistant, I discovered that a third-party had slipped a tracking tag onto a site I was analyzing.
This tracking tag could cause a privacy or GDPR violation for this website. So, I need to find the source of this tag and make sure it’s permanently removed from this website.
☐ Do you want all this tracking code in place?
Another thing I noticed in my tag assistant report is that this site I’m reviewing is sending three hits to Google Analytics. It’s possible this site is tracked in multiple Google Analytics properties for a reason. But these tags might also be an unnecessary duplication of reporting.
Try to make sure the data you’re collecting serves a purpose. Removing unnecessary tags from your site can decrease the potential for privacy violations, and also help declutter your analytics.
☐ Step #3: If you are using GTM, check your tracking tags in Preview and Debug Mode
You can also check your tracking tags inside of GTM. GTM’s preview and debug mode will show you all the Google Analytics tags that are running on your site, where your tags fire, and how they are working.
(Want to master the fundamentals of using GTM to manage your tracking tags? Sign up to join our GTM Course.)
☐ Step #4: Check every page on your site for your Google Analytics tracking code
Most content management systems (CMS’s) allow you to tag every page on your website when your install your Analytics code. But it’s a good idea to do a quick check to verify that you didn’t miss any pages when you tagged your site.
You can scan your entire website for your tracking tags using a free tool called GA checker.
☐ Go to gachecker.com
☐ Run a report for your site
When I scanned my site using GA Checker, I was able to verify within minutes that all 471 pages on my website are tagged with my Google Analytics tracking code.
☐ Tag any pages you’re not tracking, as needed
GA Checker also allows you to download a complete report of your site scan. Use your site scan report to help you find any pages where you need to add the Analytics tracking code.
☐ Step #5: Run a real-time test of your tracking
One of the best ways to validate your Google Analytics tags is with Google Analytics.
You can use the Real-Time reports in Google Analytics to verify your site’s tracking and reporting.
To run this test, visit the real-time reports in Google Analytics.
☐ Navigate to your website
☐ Open up your Google Analytics Real-Time reports in an unfiltered view
You need to use a view that doesn’t block your IP address from your Real-Time reports so that you can see the hits your sending into Google Analytics.
☐ Review the data in your Real-Time Reports
You should be able to see the page your on right inside the real-time reports.
Using the location filter you can track the geographic data your sending to Google Analytics.
You can check to make sure your source/medium is tracking correctly in the Traffic Sources report.
And you can see any events tags you triggered in the Events report.
How did your Real-Time test go? Are your Google Analytics tags working correctly?
Let’s quickly review the steps you can follow to fix any broken Google Analytics tags.
Fixing broken Google Analytics tracking tags
1. Update your Google Analytics tracking code to the latest version or install your Google Analytics code using GTM.
Updating your code, or migrating to GTM can often solve your tracking problems.
2. Add tags to any pages that are not getting tracked
As we discussed, most CMS’s allow you to tag your whole site at once. But if you’re concerned that pages on your site are not tagged correctly, use GA checker to scan your site. Then go back and tag the pages on your site that you missed.
3. Remove unnecessary tags from your website (especially from third-parties).
Third-party code can cause privacy violations. Consider removing any third-party tracking code that you find on your site.
4. Use the Real-Time test to see if the tags you updated are tracking correctly.
Using your Real-Time reports to check your tracking is a highly manual process. But the Real-Time test is also a great way to make sure you Google Analytics tags are tracking all the data you need for your analysis.
5. Periodically scan your site to make sure all your pages are tagged
You can use GA Checker to routinely scan your site and double check that all your pages have Google Analytics tracking tags.
That wraps up the basic steps in our Google Analytics tagging guide.
Want to keep going and learn how to upgrade your tagging while building a complete website tracking plan?
Join us in Analytics Course to continue with our guide.
What’s your favorite tool for checking tracking tags?
As always, I want to hear your comments and questions. Which tools do you use to check your Google Analytics tags? Tag Assistant? GTM? GA checker? Leave a comment below with your favorite tool for testing your Google Analytics tracking tags.