Shopify

The Complete Guide to Shopify Google Analytics Integration

Google Analytics enables you to measure and analyze your marketing efforts so that you’re able to optimize your website and your marketing campaigns in order to generate more sales.

It allows you to learn more about your visitors and their browsing and shopping habits, which, in turn, allows you to improve your website and increase customer satisfaction and loyalty.

Sounds important, doesn’t it? That’s because it is.

However, it’s been shown that most Shopify websites don’t use Google Analytics properly. According to Littledata, as much as 88% of Shopify businesses have issues with their Google Analytics setup.

This results in ecommerce businesses not being able to measure their ROI correctly and not having a clear view of the customer journey.

Littledata’s research reveals that the most common Google Analytics issues for ecommerce websites include:

  • Lack of product list view tracking
  • Discrepancy between order volumes in Shopify and Google Analytics
  • Disabled demographics tracking
  • Missing checkout steps
  • Lack of add-to-cart detail tracking


In this guide, we’re going to show you how to properly set up Google Analytics for your Shopify website, as well as talk about Google Analytics best practices. We’ll also give you some tips on how to use Google Analytics effectively.

How to set up Google Analytics for Shopify

Setting up Google Analytics for your Shopify website is fairly easy. Let’s go through the steps one by one.

1) Check whether you already have Google Analytics enabled

Enabling Google Analytics for your website multiple times will result in inaccurate data. If you’re not sure whether you’ve already enabled Google Analytics, go to Online store > Preferences and check if the Google Analytics box contains any code.


Google Analytics


If it does, you already have Google Analytics enabled. If the box is empty, you’ll need to enable Google Analytics by creating a Google Analytics account and generating a code for your website.


2) Create a Google Analytics account

Go to the Google Analytics website and create a new account. Under the What do you want to measure section, choose Web.


Create a Google Analytics account


Fill in your website name, URL, and industry. Finally, select the time zone you’d like to use for reporting.


Fill in your website name, URL, and industry


Click on Create.


3) Copy your tracking code and paste it into Shopify


Copy the Global Site Tag code and then open your Shopify dashboard. Go to Online store > Preferences and paste the code into the Google Analytics box.


Paste the code


4) Turn on ecommerce tracking

After you’ve enabled Google Analytics for your website, you’ll need to turn on ecommerce tracking.

Google Analytics offers two types of ecommerce tracking:

  • Basic - Shows transaction and revenue data.
  • Enhanced - Provides a variety of insights into your visitors’ behavior.


To turn on basic ecommerce tracking, log into your Google Analytics account and go to Admin > View > Ecommerce Settings. Click on Enable Ecommerce and then on Save.


E-commerce set-up


Enhanced ecommerce tracking can be turned on here or from your Shopify dashboard by going to Online store > Preferences and checking the Use Enhanced Ecommerce checkbox under the Google Analytics section.


How to use Google Analytics for Shopify

Setting up Google Analytics wasn’t so hard, was it?

Now, we’re going to go over a number of different ways you can use Google Analytics to discover relevant insights that can help you improve your website and generate more sales.


Focus on metrics you can use

There’s a huge amount of different types of data you can track with Google Analytics. However, not all of this data will be useful or helpful to you.

If you focus on irrelevant metrics and data, you’ll waste your time and potentially make the wrong decisions when it comes to optimizing your website.

What constitutes helpful data?

Helpful data is data that answers a specific question and that you can use to make a decision when it comes to implementing changes on your website. If you don’t know what to do with a particular metric, then you don’t need it (at least not yet).

Track campaign performance

Tracking your marketing campaigns and performance is perhaps the most important thing Google Analytics can help you do.

To start tracking your campaigns with Google Analytics, create a trackable URL using Google’s Campaign URL Builder.

On the URL Builder page, enter the link you’d like to track, the campaign source and medium, and the name of your campaign.


Campaign URL Builder


If your campaign is based on paid search advertising, you should also fill in the Campaign term field with the keywords you’re going to use for your ad.

Once you’ve finished entering all the information for your campaign, the Campaign URL Builder will automatically generate a trackable link for you.

Take advantage of reports

Google Analytics offers a large number of different reports you can use to learn more about your audience and their behavior, find out how your website is performing when it comes to converting visitors into customers, as well as learn more about the way your website generates sales.


Real-time reports

Real-time reports allow you to monitor your website’s traffic as it happens. They can show you who is on your website at that precise moment, where they came from, and which pages they’re browsing.

This type of report is very useful for learning how your recent social media posts or marketing emails are impacting your website traffic.

To view real-time reports, go to Real-Time > Overview. The Overview report will provide you with the most data.


Real-time reports


You can also get a more detailed view of specific aspects of your website traffic by choosing one of the other real-time reports such as Locations, Events, Conversions, Traffic Sources, and Content.

There are four different categories of reports available in Google Analytics:

  • Audience reports
  • Acquisition reports
  • Behavior reports
  • Conversions reports


We’ll discuss all of these in more detail in the following sections.

Audience reports

Audience reports provide you with detailed information about your website visitors. You can use audience reports to find out your visitors’ age, gender, language, and location, as well as find out what device they’re using to access your website.


Audience reports


In the Audience Overview report, you’ll be able to view details on the following metrics:

  • Users - Total number of unique visitors that accessed your website.
  • New Users - Percentage of visitors that visited your website for the first time.
  • Sessions - Total number of sessions visitors made.
  • Average Session Duration - Average amount of time that visitors spend on your website per session.
  • Pages per Session - Number of pages visitors view per session.
  • Pageviews - Total number of pages that visitors viewed on your website.
  • Bounce Rate - Percentage of visitors that abandon your website after viewing a single page.


Acquisition reports

Acquisition reports show you how visitors found your website. They allow you to understand which channels drive the most visitors, as well as which channels generate the most engagement and sales.


Acquisition reports


The Acquisition Overview report provides you with a quick view of your top-performing acquisition channels, including:

  • Organic Search - Denotes visitors who arrive at your website from search engine results.
  • Paid Search - Shows the number of people who come to your website after clicking on a paid search ad.
  • Direct - Visitors who come to your website after typing in your website’s address into the browser’s address bar, as well as those whose referral source can’t be tracked, will be grouped in this category.
  • Referral - The referral channel shows visitors who come to your website after clicking on a link on another website
  • Social - As the name implies, this channel includes visitors arriving from social networks.


Other useful acquisition reports you might want to take a look at include Channels, All Traffic, All Referrals, Campaigns, Keywords, Cost Analysis, Google Ads, Social, and Search Engine Optimization.


Behavior reports

Behavior reports provide you with insights on how visitors are using your website and how they’re reacting to your content. They enable you to find out which areas of your website need to be improved in order to create a better website experience for your visitors.

Behavior Overview is the main behavior report in Google Analytics. It gives you insight into metrics such as unique pageviews, total pageviews, average time on page, exit percentage, and bounce rate.


Behavior reports


There are eight additional behavior reports you can access:

  • Behavior Flow - Shows you the path visitors take on your website.
  • Site Content - Enables you to see how visitors engage with your content.
  • Site Speed - Provides details on how your website performs in terms of load speed.
  • Site Search - Shows you how visitors use your site’s search function.
  • Events - Enables you to track specific actions on your website, such as link clicks, video plays, file downloads, etc.
  • Publisher - Provides information on revenue generated from Google AdSense.
  • Experiments - Helps you A/B test landing page variations.
  • In-Page Analytics - Shows website pages along with their Google Analytics data.


Conversion Reports

You can use Conversions reports to find out what products customers are purchasing from your website, as well as how much money they’re spending. They also provide you with insight into how much revenue you’re generating, as well as the conversion rate you’re experiencing.


Conversions reports


Conversions reports also include ecommerce reports such as:

  • Product performance report - Shows the total number of products that were purchased during a specific period, as well as the revenue generated by those products.
  • Sales performance report - Similar to the Product performance report, except that the information is grouped by date.
  • Transactions report - Lists all the order data by transaction ID.


There are two different types of ecommerce reports: Standard and Enhanced. While they both essentially show the same information, Enhanced reports provide a more detailed view of all the available ecommerce metrics.

Create custom segments

In Google Analytics, segments are groups of visitors that share common traits. Users can be segmented by demographics, behavior, traffic sources, and devices used to access your website.

Most ecommerce businesses don’t put in the effort to create custom segments in Google Analytics.

This is a mistake since custom segments are crucial to understanding how different types of customers interact with your website.

To create a custom segment, visit any Google Analytics report and click on +Add Segment.


Use enhanced link attribution

Enhanced link attribution enables you to access additional information on how people interact with your pages. You can use it on your homepage and your product pages to gain a better understanding of how visitors interact with links.

This, in turn, will allow you to split test different link positions to find out which position results in the most clicks or sales.

To set up enhanced link attribution, go to your Shopify dashboard and then to Online Store > Preferences. Add the following code in the Additional Google Analytics Javascript box:

ga (‘require’, ‘linkid’);


Next, go to your Google Analytics account and then to Admin > Property Settings. Once there, click on Use enhanced link attribution and then click on Save.


In-Page Analytics


Set up custom alerts

Custom alerts allow you to stay on top of any important changes concerning your website’s traffic and sales.

For example, you can set up custom alerts to notify you when:

  • Your website receives no traffic on a particular day or experiences a sudden spike of traffic.
  • The performance of your products goes down.
  • Your website’s conversion rate decreases.


Alerts can be delivered to you by email or SMS.

Start using Google Analytics for Shopify

Google Analytics allows you to find out how your website and marketing efforts are performing so that you can optimize for better results. It’s fairly easy to set up and provides numerous benefits, so there's no reason why you shouldn't use it.

Once you set up Google Analytics, make sure to focus on metrics that can help you make informed decisions to improve your website. Remember to use Google’s Campaign URL Builder to track campaign performance.

Take advantage of all the different reports available in Google Analytics so that you can learn more about your visitors and how they interact with your website. Create custom segments of visitors so that you can gain a better understanding of your audience.

Use enhanced link attribution so that you can split test link positions and achieve better conversion rates.

Finally, set up custom alerts to be able to stay on top of important changes regarding your website’s performance.

With Google Analytics and Shopify apps like Shogun, which also collects analytics and allows you to run A/B tests, you can learn more about your audience and make more informed decisions regarding your store.

Shogun is the visual CMS trusted by the top eCommerce brands like Leesa Mattresses, Chubbies Shorts, and K-Swiss.

Contact Us