Last reviewed October 2026.
Shopify, Google Analytics and your ad platforms will almost never agree on which channel drove a sale. That isn't a bug. Each one uses a different model, window and data source. This guide explains how Shopify's own attribution works, so you know what its numbers mean and when to trust them.
TL;DR
- Shopify's default is last non-direct click over a 30-day window. It credits the last marketing touch before purchase, ignoring direct visits.
- You can switch models per report: last click, first click, any click and linear are also available.
- UTM parameters do most of the work. Shopify reads them, plus the referrer, to decide which channel gets credit.
- The _shopify_sa_t and _shopify_sa_p cookies are short-lived, widely listed at 30 minutes, not 30 days.
- Plan matters less than many guides say. Shopify says its main analytics features, including marketing reports, are on every plan. Plus adds analytics across multiple stores.
- Solo Media Group sets up attribution properly as part of builds and migrations, including accurate marketing data tracking for Time4Learning.
How does Shopify marketing attribution work?
Shopify's order attribution credits each online store order to a marketing channel, using UTM parameters and referrer data from the shopper's visits. By default it uses a last non-direct click model with a 30-day lookback. The last marketing click before purchase gets full credit, and visits where the shopper typed your address directly are ignored.
- Last non-direct click is the default for Shopify's marketing reports.
- Clicks only. Shopify counts clicks, not ad views, so view-through conversions from ad platforms don't appear.
- Online store orders. Shopify's marketing reports cover online store orders, and totals can include canceled, pending and unpaid orders. That's one reason they may not match paid revenue.

One nuance worth knowing: Shopify's help center notes that some custom reports built in its report builder start on last click rather than last non-direct click. Check the attribution setting on any report before comparing numbers.
Which attribution models does Shopify offer?
Shopify's marketing reports offer five click-based models: last non-direct click (the default), last click, first click, any click and linear. The model is chosen per report, not as a store-wide setting. So two people looking at the same orders can see different channel credit.
| Model | Gives credit to | Useful for |
|---|---|---|
| Last non-direct click (default) | The last marketing click, ignoring direct visits | Day-to-day channel performance |
| Last click | The very last visit, including direct | Seeing how many sales close directly |
| First click | The first click in the window | Understanding what brings new customers in |
| Any click | Every channel that took part | Seeing which channels contribute |
| Linear | Equal shares across all clicks | Valuing long, multi-touch journeys |
How do UTM parameters work on Shopify?
UTM parameters are tags added to the end of a link, such as utm_source, utm_medium and utm_campaign, that tell Shopify where a visit came from. When a shopper lands on your store through a tagged link, Shopify records the source and uses it to attribute any order that follows. Consistent naming is what makes the reports usable.
- Tag every link you control: emails, social posts, influencer links and ads.
- Use the same names every time. "facebook" and "Facebook" show up as two different sources.
- Keep a shared naming sheet, so everyone on the team tags links the same way.
- Don't tag internal links on your own site. It overwrites the original source.
- Check ad platforms' auto-tagging is switched on, so paid clicks arrive tagged.
| Parameter | What it records | Example |
|---|---|---|
| utm_source | Where the visit came from | newsletter |
| utm_medium | The type of channel | |
| utm_campaign | The specific campaign | fall-sale |
What do the _shopify_sa_t and _shopify_sa_p cookies do?
_shopify_sa_t and _shopify_sa_p are described in stores' cookie policies as Shopify analytics cookies relating to marketing and referrals, usually with a 30-minute lifetime. They help connect a visit to the campaign or referrer that brought the shopper in. They aren't long-term storage: claims that they keep UTM data for 30 days are wrong.

Three things worth knowing:
- They're short-lived. Most published cookie policies list both at 30 minutes, not 30 days. The 30-day figure people mix them up with is Shopify's attribution window, which is a separate thing.
- Shopify's own policy may not list them anymore. An independent check of Shopify's published cookie policy in June 2026 found neither cookie listed there.
- Shopify's visitor cookies changed this year. Shopify stopped setting its _shopify_y and _shopify_s cookies on storefronts from January 1, 2026, according to Shopify's developer changelog.
To see what your store actually sets, open your storefront, open your browser's developer tools, and look under Application, then Cookies. That's more reliable than any list, including this one. Then make sure your cookie policy matches what you find.
How cookie consent affects attribution
Shopify's cookie banner passes each shopper's choices to its Customer Privacy API, which decides whether analytics and marketing tracking can run. Shoppers who decline won't be fully tracked, so attribution reports undercount marketing in regions where consent rules apply. That's expected, and it's another reason Shopify's numbers won't match your ad platforms.
What attribution features does each Shopify plan include?
Shopify's help center says the main features of Shopify Analytics are available on any plan, and that includes marketing reports and the choice of attribution model. Shopify Plus adds analytics across multiple stores. Older guides often say attribution reports start on the Grow plan, so if you read that, check what your own admin shows.
| Feature | Basic | Grow | Advanced | Plus |
|---|---|---|---|---|
| Analytics dashboard | Yes | Yes | Yes | Yes |
| Sessions from marketing | Yes | Yes | Yes | Yes |
| Sales attributed to marketing | Yes | Yes | Yes | Yes |
| Attribution model switching | Yes | Yes | Yes | Yes |
| Analytics across multiple stores | No | No | No | Yes |
Source: Shopify's help center, checked October 2026. Plan features change, so confirm in your admin before relying on this.
Shopify Plus analytics features compared to Basic
Shopify Plus includes everything in Advanced, plus analytics across multiple stores, which matters for brands running separate stores by country. For attribution on a single store, Basic and Plus work from the same marketing reports and models. Plus matters when you need one view across several stores.
Why don't Shopify, GA4 and Meta numbers match?
Because each counts differently. Shopify uses last non-direct click over 30 days and counts clicks only. Google Analytics 4 uses its own model and identifiers. Meta can credit conversions within a day of someone viewing an ad, and within up to seven days of a click. The same sale can be claimed by several platforms at once.
| System | Default model | Counts ad views? |
|---|---|---|
| Shopify | Last non-direct click, 30 days | No |
| Google Analytics 4 | Data-driven | No |
| Meta Ads | Click and view windows set by the advertiser | Yes |
What to do about it: pick one source of truth for each decision. Use Shopify for revenue by channel, ad platforms for optimizing campaigns inside each platform, and don't add the platforms' figures together.
Can you attribute traffic from ChatGPT or Perplexity?
Often, yes. Traffic from AI assistants usually arrives with a referrer, and links from ChatGPT's search have often carried a utm_source tag, though OpenAI doesn't add it to every link. So these visits can show up in Shopify and Google Analytics as their own sources. But visits where someone copies a link or types your name after reading an answer show up as direct, so AI's real influence is undercounted.

- Look for sources such as chatgpt.com, perplexity.ai and copilot in your reports.
- Group them into an "AI" channel in Google Analytics so they don't disappear into referrals.
- Track brand searches over time as a proxy for AI mentions that never produce a click.
Do you need a third-party attribution tool?
Most brands don't until ad spend is large enough that better attribution would change budget decisions. Shopify's built-in reports cover channel performance for most stores. Paid ecommerce attribution tools add server-side tracking, view-through data and media-mix modeling, which matter most for brands spending heavily across several paid channels.
When comparing tools such as Triple Whale, Northbeam and Rockerbox, ask:
- What data does it use? Server-side, pixel or both.
- Which models does it offer, and can you match them to your decisions?
- How does it handle consent? Tracking still depends on shoppers' choices.
- What does it cost compared with the budget it will help you reallocate?
How do you set up attribution properly on Shopify?
Start by tagging every link you control with consistent UTM parameters. Then configure the cookie banner so tracking runs where it's allowed, and connect ad platforms and analytics through Shopify's official channels. Finally, choose one model per decision and review the reports monthly.
- Create a UTM naming sheet and tag every campaign link.
- Turn on Shopify's cookie banner and check consent settings by region.
- Connect ad platforms and Google Analytics through Shopify's official channels and apps.
- Agree which model answers which question, such as first click for acquisition and last non-direct click for spend.
- Review monthly, comparing Shopify against your ad platforms for trends, not exact matches.
Accurate tracking is easiest to build in during a redesign or migration. When we migrated Time4Learning to Shopify Plus, accurate marketing data tracking was one of the outcomes of the project. Time4Learning case study
Shopify marketing attribution FAQs
What attribution model does Shopify use?
Last non-direct click over a 30-day window, by default. You can switch individual reports to last click, first click, any click or linear.
How long do _shopify_sa_t and _shopify_sa_p last?
Published cookie policies usually list both at 30 minutes. They aren't 30-day cookies; 30 days is Shopify's separate attribution window. Check your own store's cookies in your browser's developer tools.
Which Shopify plan has full attribution reports?
All of them, according to Shopify's help center: its main analytics features, including marketing reports and attribution models, are available on any plan. Shopify Plus adds analytics across multiple stores. Confirm in your admin, since plan features change.
Why are my Shopify and Meta numbers different?
Shopify counts clicks with a last non-direct click model. Meta can also credit sales within a day of an ad view and within up to seven days of a click. The same sale can appear in both.
Does cookie consent affect Shopify attribution?
Yes. When shoppers decline tracking through the cookie banner, their visits aren't fully attributed, so marketing is undercounted in regions with consent rules.