Cookie consent on ShopifyThe banner is built in, your apps may ignore it
Reviewed · 7 sources
Shopify ships its own consent tooling: a cookie banner you switch on in the admin, and a Customer Privacy API that tells apps, themes and pixels what the visitor allowed.
That covers Shopify's own analytics and marketing cookies and the pixels that are integrated properly. It does not cover a tracking script pasted into the theme, or an app that never asks the API. Those run whatever the visitor chose.
Check your Shopify site
See every cookie it sets before consent, after Reject and after Accept.
What Shopify setsOn its own
_shopify_essentialOne year. Needed for the store to work.No consent needed_shopify_cmpOne year. Stores the visitor's consent preferences.No consent neededcart91 days. The shopping cart.No consent neededcart_currency91 days. The currency of the cart.No consent neededlocalizationOne year. Country and language of the storefront.No consent neededdiscount_codeSession. A discount code applied to the cart.No consent needed_shopify_analyticsOne year. Shopify's reporting and analytics.Consent required_shopify_marketingOne year. Shopify's marketing and attribution.Consent required
From Shopify's cookie policy. The older cookies are gone: _tracking_consent, _landing_page and _orig_referrer stopped being set on 15 September 2025, and _shopify_y and _shopify_s on 1 January 2026. A cookie policy that still lists them is out of date.
Built-in consent tools
A cookie banner and the Customer Privacy API
Turn the banner on under Settings > Customer privacy, in the Privacy settings section. It is shown by region and is inactive outside the regions you configure, so check that every EU and EEA country, the UK and Switzerland are covered.
The Customer Privacy API is a browser API (window.Shopify.customerPrivacy) with calls such as analyticsProcessingAllowed() and marketingAllowed(). Shopify asks developers to use it instead of reading its cookies directly.
Where the cookies come fromThe ones that need consent
App pixels and custom pixels
Pixels added under Settings > Customer events follow the visitor's choice: in opt-in regions they run only after consent. Each custom pixel has a Customer privacy setting. One set to “Not required” runs without consent, so check every pixel.
Scripts pasted into the theme
A Google, Meta or TikTok snippet added to theme.liquid loads for every visitor. Shopify's help says manually installed pixels may need a third-party banner or custom logic to honour consent.
Apps
Review, pop-up, chat and upsell apps add their own scripts. They follow the banner only if the app developer integrated the Customer Privacy API.
Embedded content
Videos, maps and social feeds placed in pages or theme sections contact their providers on load.
Make Shopify compliantIn 5 steps
- 1
Turn on the banner for the right regions
In Settings > Customer privacy, activate the cookie banner and include all the regions where consent is required.
- 2
Move tracking into Customer events
Remove tracking snippets from the theme code and add them as app pixels or custom pixels, with the Customer privacy permissions set to required for marketing and analytics.
- 3
Audit your apps
For each app that loads a script on the storefront, check whether it supports Shopify's customer privacy settings. Replace or remove the ones that do not.
- 4
Update the cookie policy
Replace the retired cookie names with the current ones, and add every app and pixel cookie your store sets.
- 5
Test from an EU location
The banner is regional. Test with an EU IP address, reject, and confirm no analytics or marketing cookie is stored.
window.Shopify.loadFeatures([{ name: "consent-tracking-api", version: "0.1" }], (error) => {
if (error) return;
const start = () => {
if (window.Shopify.customerPrivacy.marketingAllowed()) loadMyPixel();
};
start();
document.addEventListener("visitorConsentCollected", start);
});loadMyPixel is your own function. Make sure it cannot run twice.
Tools that help: tracking script blocker · Consent Mode v2 generator · cookie reference
Common mistakesOn Shopify sites
The banner is on, but not for your visitors' region
The banner stays inactive outside the configured regions. A store that only added a few countries shows nothing elsewhere.
Tracking code left in theme.liquid
Old snippets from before Customer events keep firing next to the consent-aware pixel.
A custom pixel set to “Not required”
That setting tells Shopify the pixel may run without consent. It is rarely correct for an advertising pixel.
A cookie policy with the old cookie names
_shopify_y and _shopify_s are no longer set. The policy should name the cookies the store sets today.
Checklist for Shopify sites
- Cookie banner active for every region that requires consent
- No tracking snippet in theme code
- Every custom pixel has its permissions set to required
- Each storefront app checked for customer privacy support
- Cookie policy uses the current Shopify cookie names
- Tested with Reject from an EU location
QuestionsAnd short answers
- Does Shopify have a built-in cookie banner?
- Yes. It is under Settings > Customer privacy and is shown by region. You choose the regions and the banner's text and appearance.
- Is Shopify's cookie banner enough for GDPR?
- It controls Shopify's own analytics and marketing cookies and the pixels integrated with the Customer Privacy API. Scripts pasted into the theme and apps that do not use the API are outside its control, so the answer depends on what else your store loads.
- What happened to _shopify_y and _shopify_s?
- Shopify stopped setting them on 1 January 2026. _tracking_consent, _landing_page and _orig_referrer stopped on 15 September 2025. Shopify's current list has _shopify_analytics, _shopify_marketing, _shopify_essential and _shopify_cmp instead.
- Do Shopify pixels respect consent?
- Pixels in Customer events do, in the regions where consent is required. A custom pixel follows its own Customer privacy setting, so one marked “Not required” runs without consent.
Sources
- Shopify Cookie Policy
- Shopify Help: Configuring customer privacy settings
- Shopify: Customer Privacy API
- Shopify: About web pixels
- Shopify Help: Managing custom pixels
- Shopify changelog: _shopify_y and _shopify_s cookies will no longer be set
- Shopify changelog: _tracking_consent, _landing_page and _orig_referrer cookies will no longer be set
Reviewed 20 November 2026 against Shopify's own documentation. Platforms change their cookies and consent features; follow the links for the current state. General information about EU cookie rules, not legal advice.
Other platformsAnd guides by industry
Check your Shopify siteSee what loads before consent
Free scan · every cookie before consent, after Reject and after Accept