Cookie banner & accessibility for Squarespace
About five minutes in Code injection. Code injection is on the Core, Plus and Advanced plans (and some older Business and Commerce plans), not the Personal or Basic plan.
Installation steps
Open Code injection
Open Code injection in your Squarespace site settings (search for “Code injection” if you can't see it).
Paste at the top of the Header box
Paste the snippet at the top of the Header box and save.
Turn off Squarespace's own cookie banner
If Squarespace's own cookie banner is on (Cookies & visitor data in your site settings), switch Cookie Banner off and save, so visitors don't see two banners.
Tune it in ComplyMo
Set categories, region rules and styling from your dashboard.
Copy your snippet from Install in your dashboard (Home, or a site's Widget tab) and put it first in the <head>, before any analytics tag.
Hold them until consent
Google or Meta tags you pasted into code injection yourself: change each one the same way, to type="text/plain" with data-cookieconsent="analytics" or "marketing".
<!-- Google Analytics: waits for "analytics" consent -->
<script type="text/plain" data-cookieconsent="analytics" async
src="https://www.googletagmanager.com/gtag/js?id=G-XXXX"></script>
<script type="text/plain" data-cookieconsent="analytics">
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date()); gtag('config', 'G-XXXX');
</script>
<!-- Meta Pixel: waits for "marketing" consent -->
<script type="text/plain" data-cookieconsent="marketing">
/* your Meta Pixel base code, unchanged */
</script>
