The best Google Analytics Debugging Tools

debugging-examples-and-tips

Est. reading time: 20 minutes.

If you want to make sure you are tracking accurate data (or if you want to check if you have issues with the Google Analytics setup) this article is for you.

There are multiple ways where your analytics data can be inaccurate. You can fix some of the bugs, but others are beyond your control.

Actions based on incomplete or invalid data can have a negative impact on a business  and the number of missed opportunities can increase.

debug-importance

I have divided the tools suggestions by 2 categories based on their location:

inside GA and external.

Tools for debugging inside Google Analytics

1. Google Analytics Diagnostics (inside the GA product).

Suggestion for: Everyone.

Google Analytics will check the configuration for common problems and sometimes it will report us the issues.

How you can use it for debugging:

Click on the bell icon on the top right corner to see if there are notifications triggered.

critical-notifications

Tip: Click on “Details” for each notification to learn more about it and to find possible solutions.

Learn more about the diagnostics messages here.

Limits

  • You have to wait for the issues to appear after data is collected.
  • It will tell us if an issue was fixed or not only after collecting more data.( Crawl frequency varies)

2. Real-time Reports  (inside the GA product). 

Suggested for: Everyone

Real-time Reports are great for testing.

I use them to check the triggers for the tracking code, goals, events or virtual pageviews.

How you can use it for debugging

This is an example where a link event is recorded ok.

I selected a page where I have the Google Analytics tracking code installed and also an event on a link. After clicking on the link with the event I went in GA on the “Reports” section > Real Time > Events to see if the event was triggered.

realtime-reports-event-test

These 2 sections inside Google Analytics are useful but for a full debugging I suggest using other external tools.

External tools for debugging GA 

1. Google Tag Assistant (Chrome Extension)

Google-Tag-Assistant

Suggestion for: Everyone.

This tool helps you check if  the tracking tags are installed correctly on your pages (not just GA). You can debug Google Analytics Tracking Code (GATC), Google Tag Manager (GTM), and Adwords Conversion Tracking.

How you can use Tag Assistant for debugging:

I will show you some examples with notifications that may or may not appear.

1. “No tags found”.

tag-assistant-no-tags-found

Solution:  Add the Google Analytics tag in the website source code. (Even if it seems obvious, some people forget to do this.)

2. “Code found outside of <head> tag.”

notification-blue-tag

ga-tracking-code-outside-head

Solution: Move the tracking code inside the <head> tag. (This is the recommended location of the from Google)

3. “Same Web Property ID is tracked twice.”

same-property-id-tracked-twice

tag-assistant-multiple-codes

Solution: It is recommended that you keep only one tracking code.

This notification usually means you are using 2 instances of the same tracking code on the website.

Scenario example for this case: you could have the tracking code added in Tag Manager but also from another source (like a plugin; Ex.: Yoast).

If you want to see more information about Google Tag Assistant check this video:

There is also a video from Google showing how to use the recording function.

     Limits:

  • It can’t check all the tags that don’t fire (as they are either broken or waiting for an event to occur first)
  • It can’t scan all the pages from the website automatically.

Tip for checking tags:

Besides checking your website/s, you can also check other websites to see what kind of tags they are using. You can check for example if a website has a remarketing tag.

remarketing-tag

Besides checking the Google tags you can use another extension like “Ghostery” or “Builtwith” to check other tags.

2. GA Checker (online web tool)

Suggestion for: Everyone.

This online tool can check the presence of the GA code on multiple pages of a website.

Limit: Analyse up to 10,000 Pages.

How you can use GA Checker:

Just add your website address and wait for it to scan the pages for the tracking code.

The tool can scan a website for the presence of the following tags:

  • Google Analytics (ga.js)
  • Google Analytics Remarketing (dc.js)
  • Google Universal Analytics (analytics.js)
  • Google Analytics Experiments (ga_exp.js)
  • Google Tag Manager (gtm.js)
  • Google AdWords Conversion (conversion.js)
  • Google AdWords Phone Conversion (loader.js)
  • Google AdWords Remarketing (conversion.js)
  • Google AdWords Dynamic Remarketing (conversion.js)
  • Google DoubleClick

3.  Google Sheets or Excel to make a Health check report

Suggestion for: Everyone.

I suggest using a tool like Google Sheets or Excel to make a health check report for monitoring the implementation and to know exactly what the status is on your data.

Tip: If you want to find out details about making a health check report I suggest reading the book  “Successful Analytics” by Brian Clifton.

Suggestions for intermediate and advanced users

4.  Chrome Developer tools (tool inside Google Chrome)

If you have Google Chrome you can activate this tool with the shortcut: CTRL+SHIFT+ I (without installing anything else)

Events testing example:

Make sure you are in the “Console” tab and add the code below if you are using Universal Analytics code (analytics.js)

console-event-code

If the event tracking works ok you will get this alert box:event-confirmation-screen

If the event tracking doesn’t work you could get an error like this one:

ga-console-not-defined-error.png

The code used for testing events (the Universal Analytics format):

ga('send', {
  'hitType': 'event',         
  'eventCategory': 'button', 
  'eventAction': 'click',     
  'eventLabel': 'contact form',
  'hitCallback' : function () {
      alert("Event received");
   }
});

5. GA Debugger (Chrome extension)

google-analytics-debugger

By activating this extension and using it with Developer Tools, you can test adding a new code without uploading it to the server.

New event code testing scenario

On Chrome, load the page where you want to test adding a code for an event.

Right click on the link and select “Inspect element”.

Click on “Preserve Log” and add the code event.

After you will click on the link, new event data should show on the Developer Tools Console.

6. Screaming Frog (desktop software currently at £99)

screaming-frog

If GA checker isn’t enough for your website, you could try a paid alternative like Screaming Frog.

How you can use Screaming Frog:

There are articles on the web on how to check the tracking code on multiple pages using this tool: Check the tutorial from Insideonline  or the one from Seerinteractive

7. Fiddler (free desktop software)

How you can use Fiddler

Install and open Fiddler, type website URL in the box on the bottom of the software screen and press enter.

*Note: I have installed Fiddler 2 on my PC (because I have Win 7).

fiddler-domain-name

 

Select the sessions with the host “www.google-analytics.com” and choose “Inspectors” and “WebForms”.

fiddler-virtual-pageview.png

If you want, you can use the “Filters” tab and select “www.google-analytics.com” to show only GA data.

filters-fiddler-ga

How an event is reported for Classic analytics (ga.js)

fiddler-events

How an event is reported for Universal Analytics (analytics.js)

universal-analytics-fiddler-event

There is also a video tutorial on youtube:

 

 

Leave a Reply