Shopify Tracking Not Working? How to Test and Debug GTM, GA4 and Google Ads
By Alessandro Colarossi, Founder, Triangle Digital · Published · 10 min read
Short answer
To debug Shopify tracking, open GTM Preview (Tag Assistant) on your store and place a test order while watching three things: the data layer message for each event, which tags fired (and how many times), and whether GA4 DebugView and the platform's own tools received the event. Most problems are one of five causes: GTM missing from checkout, a Customer Events pixel that is saved but not connected, duplicate sources, malformed value or items, or consent blocking the tag.
The debugging toolkit
- GTM Preview (Tag Assistant): shows the data layer, variables, tags fired, and consent state for every event. This is your primary tool.
- GA4 DebugView (Admin → DebugView): confirms events actually reach GA4 and shows their parameters. Sessions from GTM Preview appear here automatically.
- GA4 Realtime report: a quick sanity check that events arrive.
- Browser DevTools, Network tab: confirms requests leave the browser. Filter for
collect(GA4) orgoogleadservices/doubleclick(Google Ads conversion requests). - Platform helpers: Meta Pixel Helper and Test Events, TikTok Pixel Helper, Pinterest Tag Helper, UET Tag Helper, Snap Pixel Helper.
Step 1: Place a test order
You need to complete a purchase to test purchase. Options, from least to most intrusive:
- Shopify Payments test mode (or the Bogus Gateway on a development store) with Shopify's published test card numbers. No money moves.
- A real order using a 100% discount code, if test mode is not available.
- A real low-value order that you refund afterward.
Test orders can pollute your reports. Mark them (for example with a tag or a distinctive email) so you can exclude them from analysis.
Step 2: Walk the full funnel in Preview
Click Preview in GTM, enter your store URL, and connect Tag Assistant. Then move through the journey and verify each stage:
| Action | Expected event | Confirm |
|---|---|---|
| Open a collection | view_item_list | items populated, item_list_name set |
| Open a product | view_item | value, currency, items correct |
| Add to cart | add_to_cart | Fires once; quantity and price correct |
| Open the cart | view_cart | Cart total matches |
| Start checkout | begin_checkout | Fires once per checkout start |
| Submit shipping, then payment | add_shipping_info, add_payment_info | Each fires once |
| Complete the order | purchase | Fires exactly once; transaction_id equals the Shopify order ID; value matches |
For each event, open the Data Layer tab to see what was pushed, then Tags to see what fired. A tag listed under “Tags Not Fired” means its trigger did not match. Check the event name spelling and trigger type first.
Symptom to cause to fix
| Symptom | Likely cause | Fix |
|---|---|---|
| Storefront events work, no checkout or purchase events | GTM only in theme.liquid, which does not run in checkout; or pixel not connected | Add a custom pixel under Customer events that loads GTM, then Save and Connect. See GTM setup. |
| Purchase counted twice | Sent from both theme and pixel; another app or hardcoded snippet also fires; or the thank-you page was reloaded | Send purchase from one place only, remove duplicate sources, and always include a unique transaction_id so platforms can de-duplicate. |
| Revenue wrong in GA4 or Google Ads | value sent as a string, mixing tax/shipping definitions, or wrong currency | Send numeric values, use one value definition everywhere, and send the customer's currency code. See GA4 purchase checklist. |
| Events fire but no products in reports | items missing or empty, or Data Layer Variable path wrong | Confirm ecommerce.items exists in the Data Layer tab and that the GA4 tag has Send Ecommerce data set to Data Layer. |
| Works in Preview but not on the live site | Container not published, or pixel still points to an old container ID | Submit and publish the container, then recheck the live site without Preview. |
| Sales attributed to paypal / referral | Payment redirect starts a new session | Add the payment domains to GA4 List unwanted referrals. |
| Google Ads shows no conversions | Missing Conversion Linker, wrong Conversion ID or Label, or still waiting on a first conversion | Verify the tag in Preview, check IDs, and see the Google Ads guide. |
| Page views doubled | page_view sent by both theme and pixel, or two GTM containers installed | Pick one source per event and remove the extra container. |
| Tags never fire for some visitors | Consent denied, ad blockers or browser tracking prevention | Check the Consent tab in Preview. Some loss is expected; see Consent Mode v2. |
Step 3: Confirm in GA4
- In DebugView, click each event and check its parameters:
transaction_id,value,currency, and theitemslist. - In Realtime, confirm you see the events and the correct page paths.
- After processing, the Monetization → Ecommerce purchases report should list your test product and revenue. Standard reports can lag by a day.
- Compare real orders against GA4 transactions over a few days. Expect a modest gap from consent and ad blockers, and investigate large or variable gaps.
Inspecting the data layer on the storefront
On a storefront page, open the browser console and type dataLayer to see everything pushed so far, or google_tag_manager to confirm the container is loaded. If a view_item push is missing here, the problem is in your theme snippet (see the data layer guide), not in GTM.
After you fix something
- Re-run a full test order. Do not assume a fix to one event left the others intact.
- Publish the container with a descriptive version name so you can roll back.
- Watch the numbers for several days against Shopify orders.
- Document your setup (container ID, pixel version, who owns what) so the next change is safe.
Start from a tested baseline
Debugging is far quicker when the foundation is known-good. The Shopify DIY Tagging Packs ship with testing and validation guidance and 30 minutes of implementation support, so if something does not fire you are not troubleshooting alone. You can also book a free support call.
Frequently asked questions
Why is my Shopify purchase event not firing in GTM?
Most often GTM is installed only in theme.liquid, which does not run on checkout, or the Customer Events custom pixel is saved but not connected. Add a connected pixel that loads GTM and pushes checkout_completed as purchase.
Why is my GA4 purchase event duplicated on Shopify?
Usually the purchase is sent from two sources: the theme and the pixel, or a legacy snippet or app plus GTM. A reloaded thank-you page can also re-fire it. Send it once and include a unique transaction_id.
How do I test Shopify tracking without a real purchase?
Use Shopify Payments test mode or the Bogus Gateway on a development store with test card numbers. If unavailable, use a 100% discount code order or a low-value order you refund.
Why does GTM Preview work but my live site does not?
Preview runs your unpublished workspace. If the container has not been submitted and published, the live site still runs the old version.
How accurate should GA4 be compared with Shopify?
Expect GA4 to be modestly lower because of consent declines, ad blockers and order types GA4 never sees. A large or fluctuating gap points to a tracking problem.
