Insights

How to Verify Google Analytics Code with Screaming Frog

The paid version of Screaming Frog is a lifesaver! I use Screaming Frog regularly to make sure the correct Google Analytics code is in place on every page of a website. Just because the code is in place on the homepage doesn't mean the same code is on every page. Some pages could be totally missing the code while others could have different versions.

Here is a quick process for verifying or checking your Google Analytics code in Screaming Frog.

Start by selecting Custom Filters under Configuration.

Checking Code in Screaming Frog

Determine what you want to search for in the filters. I usually have one filter showing pages that do contain information I'm looking for then pages that don't contain it.For example, filters 1 and 2 will usually be pages that do or don't contain the UA number.

For the example below, I used SEER's UA: UA-11852503-1.

Google Analytics Code in Screaming Frog

If a site uses cross domain tracking because it spans multiple domains or subdomains, grab the line of code for cross domain tracking and drop it into filters 3 and 4. Make one filter Contains and the other filter Does Not Contain.

For the example below, I used setDomainName', 'seerinteractive.com.

Check for Google Analytics Code

For filter 5, try adding a snippet from the second portion of the GA code. I've been surprised by the number of sites that drop off the second portion and keep only the top part of the code.

For the example below, I used google-analytics.com/ga.js.

Verify Google Analytics Code

Once the settings are all in place, enter the URL in Screaming Frog and hit Start.

How to Check Google Analytics Code

From there, go to the Custom tab. The data that shows up will be for any of your filters. You can quickly scan the filter data for issues, or can export data from each of the filters to a CSV for further analysis or to send to the client.

Using Screaming Frog to Verify Code

Disclaimer for Running on Client Sites

If you're running Screaming Frog on a client's site, give them a heads up first. Without that warning, someone may see the tool hitting their site quickly and think there is an issue.

Let me know if you use Screaming Frog to check for GA code too, or if you have other methods you currently use.

Still nerding out on technical SEO? Check out our open positions.

SIGN UP FOR NEWSLETTER

We love helping marketers like you.

Sign up for our newsletter to receive updates and more: