Skip to content
Setup GA4 on Shopify with Shopify GA4 Kit
Share
Explore

Step-by-Step Checklist

Here is a checklist of each step for our awesome Shopify GA4 Kit 🤩
You can check them as you go, take a break, and come back later to finish up!
(PS. If you feel lost at some steps and need more detailed guidance, feel free to check our or comprehensive .)
Let’s start:
Step 1️⃣
Add GTM on Shopify.
(If you already have Google Tag Manager installed on your store, you may skip this step.)
Set up & validate Google Tag Manager on your Shopify store with our .
Step 2️⃣
Get the Shopify purchase data layer (inc. product-level data).

Copy the code block (just click the “Copy Code” button on the top-right corner 😉👍).
Step 3️⃣
Add data layers to checkout.

Paste the code block in your “Additional Scripts” under the GTM container code.
(Go to your Shopify Admin page > “Settings” > “Checkout” > “Order Status Page” > “Additional Scripts”)
Step 4️⃣
Add data layers to the product page.

Copy the code block .
Open the page to edit your Shopify theme.
(Head to Shopify Admin page > “Online Store” > “Themes”, then choose “Live Theme” > “Actions” > “Edit Code”)
Add a new snippet.
(Scroll down to “Snippets” > “Add new snippet”, name it “analyzify-product-datalayer” and click “Create”)
Paste the code block you copied in the first step in this newly created snippet and click “Save”.
Open the theme.liquid file (under the “Layout” section), search for “/head”, and paste this code above </head>:
{% render 'analyzify-product-datalayer.liquid' %}
Step 5️⃣
Download the GTM container.

Analyzify’s free & comprehensive GTM container.

(Click on “Kit Part 2: GTM Container” and then “Click here to request the GA4 recipe to your email”. Enter your information and your container will be on its way!)
Step 6️⃣
Import the GTM container.

Log in to your GTM > Click “Admin” (top menu) > “Import Container
Choose the JSON file you’ve downloaded.
Choose “Existing Workspace”, “Merge”, and “Rename conflicting tags, triggers, and variables.
Click “Confirm”!
Step 7️⃣
Add your GA4 Measurement ID.

In the container, click the variable named “***UpdateMe*** GA4 Measurement ID (G-)”.
(You can also find it on Google Tag Manager > “Variables” (left-menu) > “User-Defined Variables”)
Paste your GA4 measurement ID here. ()
Click “Save”!
Step 8️⃣
Pause other GA4 tags.

Pause any GA4 tags you’ve added before to prevent double-tracking.
(Click the pause icon on the top-right corner.)
Step 9️⃣
Validate your GA4 setup.

Head to GTM and click “Preview” (top-right corner).
Add your store URL and click “Connect”.
(Your store should open and it should write “Tag Assistant Connected” on the bottom-right corner.)
Visit a product page and go back to “Preview Mode: Tag Assistant”.
Click on the “analyzify_productDetail” event on the left.
Click on the “GA4.02 - Event - View Item” tag.
Choose “Display Variables as Values” from the right top corner.
Double-check the:
Product ID
Product Name
Product Price
Google Analytics 4 measurement ID.
Step 🔟
Complete your tests & publish.

Click “Submit” (at the top-right corner of GTM), write a container name, and “Publish”.
(Optional: Before publishing, you can also test the purchase event the same way as above. For more info and further tests, visit our !)
All done! Your GA4 setup is now ready for you to enjoy 🤓 🎉

Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.