On this page
Before you start
On Shopify, you add the CookieScan install code to your theme's theme.liquid file. It then loads on every page that uses your theme.
You need:
- your install code, from Cookie Banner, then Install Code, then Manual Install
- a Shopify account that can edit your store's theme code
If you manage your tags in Google Tag Manager, follow Install with Google Tag Manager instead.
Back up your theme
Make a copy of your theme first, so you can go back if something goes wrong.
Open your themes
In your Shopify admin, go to Online Store, then Themes.
Duplicate your current theme
Open the menu next to your current theme and select Duplicate.
Add the code to theme.liquid
Open the code editor
On your current theme, open the menu and select Edit code.
Open theme.liquid
Under Layout, select
theme.liquid.Paste the install code
Find the opening
<head>tag near the top. Paste your install code on the line straight after it.Save the file
Select Save.
The top of theme.liquid then looks like this:
<head>
<script src="https://banner.cookiescan.com/js?id=YOUR-COOKIESCAN-ID"></script>
<meta charset="utf-8">Keep the CookieScan script above every other script in <head>. Auto-blocking can only hold back scripts that load after it.
Show only one cookie banner
If Shopify's own cookie banner is turned on, visitors see two banners. Turn Shopify's banner off in your store's customer privacy settings.
Shopify's own tracking, such as its customer events, follows Shopify's privacy settings rather than your CookieScan banner.
Pages CookieScan doesn't reach
Your cookie banner doesn't load on Shopify's checkout pages, because your theme's code doesn't run there.
Check it worked
Open your store in a private browser window. Your cookie banner appears within a few seconds. Make a choice, then check that the Dashboard shows Receiving consents. See Check your banner is working.