Logo

Don't Use Google Analytics to Analyze Shopify Sales Data

Why you should use Shopify for sales data and Google Analytics for website data.

·6 minutes reading
Cover Image for Don't Use Google Analytics to Analyze Shopify Sales Data

Performance tracking tells us what is going on with our stores:

  1. Are sales up or down?
  2. Where is the traffic coming from?
  3. Where are the buyers coming from?

Shopify stores need sales data and website data to answer these questions.

Sales data is the stuff that actually happens in our Shopify database, like orders and customers. With it, we can answer questions such as “What is our average order value?” or “How many returning customers did we have?”

Website data is the stuff that happens in visitors’ browsers, like traffic sources and pageviews. With it, we can answer questions such as”How do visitors find our website? or “Which product details do they view?”

The best sales data comes from Shopify, and the best website data comes from Google Analytics. Use the right source, or you’ll get the wrong answers.

Get accurate an complete ecommerce data in Google Analytics 4

Use Shopify for Sales Data

Shopify is the single source of truth for your sales data. There isn’t an order (or customer, or return) from your store that doesn’t exist in Shopify. It’s the complete dataset.

The ecommerce data in Google Analytics, by contrast, is at best an approximation of your sales data. Therefore, to find metrics like average order value or new and returning customers, you should use Shopify, not Google Analytics.

There are several advantages to doing so.

Historical Data

With Shopify, we get perfect historical data. That means we can accurately view the entire history of our store even if we didn’t install Google Analytics (or any other tool) until a few months after starting our store.

image

Non-Website Orders

Shopify has all our orders, even those that weren’t made on our website. Orders placed over the phone or recurring orders placed through subscription apps like Recharge all end up in Shopify but not Google Analytics.

Retroactive Updates

Along the same lines, we’ll often discover that when we start our analysis, we need to change how we think about your data. For instance, Rebuy, a Shopify app for one-click upsells, creates a new order for every upsell item. But when calculating average order value, we don’t want to consider upsells as separate orders.

With Shopify data, we can simply update our spreadsheet (or Data Studio connector) to account for the upsells, and our historical data will update as well.

In Google Analytics, the best we can do is note that from this day going forward, we changed the way we calculate order values.

image

Consequently, with Google Analytics you won’t be able to answer questions like “How has our average order value changed over the past six months?” with any degree of accuracy. It’s mostly useless for these kinds of questions.

Debug with Actual Actuals

I’ve heard some stores use the term “estimated actuals” when talking about ecommerce metrics. While an oxymoron, it does highlight a good reason to use Shopify for sales data. It’s our “actual actuals”.

All the other marketing tools we use—Facebook ads, Google Optimize A/B testing, Adwords remarketing—are separate pixels and are thus going to have their own numbers for purchases.

If working correctly, those numbers will be accurate to plus or minus 10%. But sometimes they’re not working correctly. To figure out what’s wrong, we need to compare their numbers to our actual sales data from Shopify, not estimated sales data in another tool.

What is Google Analytics E-commerce for Anyway?

All this isn’t to say you shouldn’t set up Google Analytics Enhanced Ecommerce tracking. For one, you’ll need it to do Optimize A/B testing. More importantly, as we’ll see, you’ll need it to enrich your Shopify data with traffic source information.

But you shouldn’t use it to analyze sales data. After all, Shopify has the real data, so why not use it?

Use Google Analytics for Website Data

Conversely, for website data, we should use Google Analytics, even though Shopify has built-in website analytics tracking.

Referral Exclusions

Shopify’s built-in analytics solution is missing important features like referral exclusions, so if we have a custom landing page or checkout experience, we can’t attribute traffic correctly.

As a result, we’ll see most or all of our sales attributed to “direct traffic” in Shopify.

image

We may also see the landing page or checkout experience listed as a referrer.

image

Custom Events

Unlike Shopify, Google Analytics also lets us track custom events. For instance, we may want to track when visitors sign up for our newsletter.

image

Visitor Tracking Over Time

Finally, Google Analytics does a better job of tracking visitors over time. Suppose a visitor clicks a Facebook ad to our website on Monday, looks at a few product detail pages, and leaves. Then, they return on Friday and make a purchase.

Assuming the visitor uses the same browser, Google Analytics “knows” that the Monday visitor and the Friday customer are the same person and can therefore attribute the Friday purchase to the Monday Facebook ad, like so:

image

Shopify can also track visitors like this, but it’s less robust.

No Single Source of Truth for Website Data

Now, it’s important to note that unlike Shopify sales data, we can’t treat Google Analytics (or any website tracking tool) as a single source of truth for our website.

For one thing, we won’t be able to track any visitors that have ad blockers installed. More importantly, though, no Google Analytics setup is perfect from day one, and we can’t retroactively track new website events. For instance, if we only started tracking add to cart events today, there’s no way to know the add to cart events of previous visitors.

With website tracking, we don’t need perfect data—better is the enemy of good enough. Just keep in mind that, unlike sales data, it’s always an approximation.

Google Analytics Alternatives

There are a few other website analytics tools you should consider in addition to Google Analytics.

The first is Google Analytics 4 (GA4). GA4 is not just an upgrade to traditional Google Analytics. It’s a totally different tracking system. I won’t go into the details here, but it’s worth considering because it tracks visitors across devices better than traditional Google Analytics.

The second is Mixpanel. Mixpanel lets you create funnels other than the standard ecommerce funnel available in Google Analytics.

image

If you use quizzes or signups to drive sales, Mixpanel may be worth the cost.

Attributing Sales to Traffic Sources

The most important question for performance tracking is “What sources of traffic are driving purchases?”

To answer, we need a combination of website data (sources of traffic) and sales data (purchases).

Since our website data is tracked in Google Analytics, and our sales data is tracked in Shopify, how can we answer this question?

To do so, we combine our Google Analytics and Shopify data. Here’s how.

Combining Shopify and Google Analytics Data

First, set up Google Analytics Enhanced Ecommerce in your Shopify store. To start with, the default Shopify plugin is fine for most stores.

Go to Online Store > Preferences > Google Analytics

image

Then, make a test purchase to ensure that the Enhanced Ecommerce transaction ID matches the Shopify order number using this custom report:

image

Once you’re tracking orders in Google Analytics with the same order number assigned in Shopify, you can link the two data sources together based on that order number.

To do so, download your Shopify orders and your Google Analytics transactions (use the custom report, as above) and import that data into this spreadsheet per these instructions:

After doing so, you’ll end up with a table like this:

image

If that becomes too cumbersome, use a Google Data Studio Shopify connector to do it automatically.

This attribution table is frequently the single most valuable tool in our performance analysis toolkit. It connects the dots between where customers come from and what they purchase. With it, we can find out how to drive more sales and increase our profits.