FROM CACHE - en_header

GDPR Banner: How do I halt Shopify Cookies and Native Analytics Tool until User Consent ?

Shopify Partner
29 0 0

I want to a build a GDPR-compliant Banner for a store in the EU.

I've checked out some relevant apps on the App Store and realised they are not really EU-compliant. They just show a banner but they don't really do anything else behind the scenes. They don't really prevent Shopify cookies from being stored (if they client doesn't give their consent) nor do they prevent the internal/native Shopify Analytics tool from running (if the client doesn't give their consent).

I want to build my own custom GDPR banner just to be on the safe side.

When the store loads for the client the first time, I want to provide the client with a banner with an "Accept" and a "Refuse" button.

  1. How do I prevent the internal/native Shopify Analytics tool from firing until the user clicks on the "Agree" button, using Javascript or Liquid or a combination of the two ? For example, I know how to load a Google Analytics script conditionally using Javascript. But what about this internal/native Shopify Analytics tool?
  2. How do I prevent Shopify from storing any cookies until the user clicks on the "Agree" button? I know how to delete them if the user clicks on "Refuse" but how do I prevent them from even being stored in the first place, until the user click on "Agree" ?
Replies 0 (0)