Webclat / Ecommerce
ecomm.webclat.com

Why don't my UTM campaign parameters get attributed correctly to the resulting Shopify order?

UTM capture depends on a cookie surviving from click to purchase. Any of five specific breaks can sever that chain before the order ever records it.

Quick answer

Shopify only captures UTM parameters into its order attribution fields when they're present on the first page of that browser session, stored against a cookie-based session with an expiry window. If a shopper clears cookies, switches devices, browses in a mode that blocks long-lived cookies, or a later visit overwrites the earlier one under Shopify's last-non-direct-click model, the UTM never reaches the order record.

Why this happens

Shopify's own order-level attribution (the "referring site" and campaign fields visible on an order) is built on first-party cookies that capture the landing page's UTM parameters and persist them across the session. That mechanism has several structural weak points: the cookie can be cleared or blocked, the checkout can run on a domain that doesn't share the same cookie jar, the journey can span devices with no shared identifier, and - by design - a later non-direct visit before purchase overwrites an earlier one under Shopify's last-non-direct-click attribution model. None of these are bugs; they're the known limits of cookie-based attribution running into normal browsing behavior.

Fix it

  1. Confirm the UTM actually reaches a storefront URL intact - check your ad platform's final/landing URL setting for a redirect chain that might be stripping query parameters.
  2. Confirm cookies are enabled for the storefront domain for the traffic source in question. Shopify's attribution cookies are first-party but are still subject to browser-level caps (such as Safari's Intelligent Tracking Prevention) on cookie lifetime for some referral paths.
  3. If checkout redirects to a separate myshopify.com or shop.app domain, check whether "checkout on your domain" is available on your plan (Settings > Domains) - unifying the checkout domain removes an entire class of cross-domain cookie loss.
  4. For GA4/GTM-side attribution specifically (separate from Shopify's own order field), make sure the UTM is captured into the session before any redirect, and that the client id and any ad-click id survive into the checkout_completed pixel event - pass them through explicitly as custom-pixel data if they need to appear on the purchase event itself.
  5. Recognize what cookie-based UTM capture cannot solve: a cross-device journey (ad click on mobile, purchase on desktop) will never attribute correctly through cookies alone. That needs a different measurement layer - platform-side conversion matching on a hashed identifier, not UTM capture.
  6. Check whether a marketing app (loyalty, referral, or email tools) is overwriting the landing-page cookie on a later visit. Under the last-non-direct-click model, any later visit before purchase - including one triggered by an app's own link - replaces the earlier ad click's UTM.

Branch: if the order's own Shopify attribution shows the UTM correctly but your GA4 session-level report doesn't (or vice versa), the break is specific to whichever system's capture point the parameter didn't reach - they are two independent capture mechanisms, not one shared pipe.

How to verify it worked

Runtime check

Clear cookies (or use a private window), visit the store via a link carrying known UTM parameters, and place a test order. In Shopify admin, open that order's additional details and check for the captured referring-site/UTM fields. Separately, in GA4 Explore, build a session-scoped source/medium report filtered to that timeframe and confirm the same test session shows the matching campaign. If one system shows the UTM and the other doesn't, use the browser's Network tab through the funnel to see exactly which page the querystring stopped surviving on - that page is the break.

Find out what your tracking actually reports.

A runtime audit of your store: every tag that fires, every event that reaches your analytics and ad platforms, and where the numbers diverge from the orders table. Evidence first, opinions second.

Request an audit