Skip to content
Activate Shopify Analytics in Webflow

Shopify Analytics

Shopify Headless has a built-in analytics for “page-views” and “add-to-cart” events. Naturally be aware that making up analytics from a website nowadays is not reliable at all. Most browsers (Firefox by default, Chromium when set in “Do not track” mode) will block automatically all analytics scripts.

We advice to use the native Shopify Cookie Consent system that automatically allows consent both in Webflow and Shopify, allowing you to track pixels both in Webflow and Shopify checkout.

To activate the Shopify page views and product add to cart analytics with your own cookie consent system you just need to call the JS function:

Smootify.enableAnalytics(true);

after receiving the user consent. Follow up the documentation of the cookie consent system of your choice in order to run the previous code properly only when user accepted analytics.

A part from running up that code to enable the page-views and add-to-cart events, you have also to give Shopify consent to track using Shopify Customer Privacy APIs.