How to Add Google Analytics Tracking on a Shopify Thank You Page

You’ve setup Google Analytics on your Shopify store. You’ve gotten some customers and now you’re hungry for global domination. You now turn to data and analytics, hoping to glean some insights about your customers, what they’re doing on your site, and how they are converting.

Before you’re able to run a funnel analysis and perform some wizardry with your customer segments, you first have to make sure that you’re actually tracking each page of your conversion funnel including your checkout thank you page. You can do this by using the Google Analytics built in goals functionality.

In this article, you will learn more about:

  • What are Google Analytics goals
  • How goals work
  • How to set up checkout thank you page goals

What are Google Analytics goals If you haven’t heard of Google Analytics goals before this, you’re in for a treat. Goals are used to measure how often users complete specific actions on your site. You’re able to use goals to measure how your site measures up against your targets. A goal is really a defined end action achieved by a user on the site. Google Analytics calls this a conversion, activities that help you measure your business success. Say for example you’d like to know whether your investments in paid ads actually results in purchases on your site. You do want to get your money’s worth after all. To do this, you need to first setup a goal with the purchase thank you page, add it to your campaign report and take note of which campaigns are performing better at converting your users into customers.

Google Analytics counts each time a user on your site accomplishes one of your defined goals as a conversion. In our example, none of our campaigns are generating any sales!

If we hadn’t defined any goals, we wouldn’t be able to accurately measure how we’re doing. Goals help you figure out whether you need to make improvements to your digital analytics strategy, provide you honest feedback on how you’re doing, and gives you critical insights into how your conversion rates.

How goals work Goals are configured at the view level. This means that each view in your Google Analytics account will have its own set of goals which you can choose to keep consistent or different across your account views.

You can make a goal as specific as you want, triggering the goal when a user views a particular destination page, how long they spend on the site, the number of page views per session (Unsure on what exactly are page views and sessions?), and even whether specific events were triggered. You’re also able to attach an optional monetary value to a goal which you’ll see in your reports as the Goal Value.

Important: Goals are not retroactive. Any data you collect prior to a goal being setup will not be reflected in your goal reports. They only start applying to the data you collect after they’ve been setup. You’ll be able to see basic goal data appearing immediately as they happen in the real time reports.

How to setup checkout thank you page goals You’ll have to login into your Google Analytics account to setup goals. If you haven’t already created a Google Analytics account, I suggest you create an account following these instructions: https://support.google.com/analytics/answer/1008015?hl=en

Once you’re logged into your Google Analytics account, you’ll need to select Admin and the View you’d like to create the goal in.

You’ll be presented with a three step process like the one below:

In step 1, select Custom (it makes life easier here as the suggested templates differ depending on which industry category your business is in).

In Step 2, give your goal a meaningful name like “Checkout Purchase” and select the destination type.

In step 3, you’ll want to enter the goal details as I have it below. I’m using URLs from Shopify’s own recommendation on screen URLs to be used that you can find here. Note that I’ve selected equals to as the match type. You’re able to use regular expression if you’re comfortable with it, just make sure that your regular expression is valid and matches the checkout screen URLs.

A funnel represents the pages your users take to reach the goal destination. As we would like to know more about our conversions and if they’re dropping off at any stage, choose to enable the funnel option and enter the steps leading to the thank you page as below. The match type for the funnel steps uses the same match type specified for the destination.

Shopify utilizes a fake page view to generate the screen URLs mentioned. It’s a way of generating a page view for page reporting when a page doesn’t actually load a new page. The URLs don’t actually exist if you compare what’s above to what you see in the URL address bar.

Save this goal and you’re done!

Final Words

You can now make use of this newly created Checkout Purchase goal in your reports. Conduct a funnel analysis to see where people are dropping off and what’s the conversion rate from each step of the funnel. Here are some other helpful reports you can find in Google Analytics.

If you’re encountering any problems with setting up your goals or would prefer for someone like ourselves to help set them up for you, feel free to check out services offered under our monthly plans at https://hitmetrics.io/.