All things Shopify and commerce
Hi!
I'm trying to set all the default consent cookies to "denied" using Customer Privacy API in a script in liquid file (below content_for_header so that to be called immediately) like this:
window.Shopify.customerPrivacy.setTrackingConsent({
"analytics": false,
"marketing": false,
"preferences": false,
"sale_of_data": false,
}
but it seems that is not working. I still see a gtag that set the default values the granted.
What I'm doing wrong? There is any solution without the need for yet another app?
Thank you!
The Best way to set cookie consent V2 banner using google approved CMP like cookiebot and Google tag manager(GTM).It works 100%. Events fire only when users give consent.
We are using cookiebot and GTM. We reached to set the first default consent to denied but we still see an second call setting those default values to denied like in the attachment:
Can i inspect your GTM setup?
Hi @gjulio96
The code you are using:
window.Shopify.customerPrivacy.setTrackingConsent({
"analytics": false,
"marketing": false,
"preferences": false,
"sale_of_data": false,
}
only comply Shopify customer privacy.
I recommend you using a consent banner app to stay compliant with Google Consent Mode v2.
Our app Consentik to stay compliant, Google Consent Mode V2 is available in Premium plan.
Please tell me if you have any concerns with app
In Canada, payment processors, like those that provide payment processing services t...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025