How to Install a Cookie Notice on your website (Not the eating kind, sadly)

How to install a cookie notice - Maddy Shine

So, now you’ve got Google Analytics all nicely set up on your website tracking the movements of your site users. The important next step that many people don’t realise, is that you need to have a Cookie Notice set up on your site to notify users that you are collecting data from them.  In this blog post, I share how to install a cookie notice on your website. This is a legal requirement, but have no fear as this is very very easy to set up and we’ll show you how, step by step.

We've all seen the mildly irritating popup notices on major websites where we're told that we're being tracked and we may click OK and move on. Actually, many of us may not understand what's actually happening.

(Not this kind of cookie, sadly)

Cookies help websites remember who you are and store important information about you, an example being when you sign into your Gmail account and it says 'Welcome Back...Maddy'.  Cookies are really important for marketing to people as it's how we know more about the customer.

There are two types of cookies:

  1. First party cookie - the cookie data is only accessible by the domain name that's throwing the cookie. These are "good" cookies.
  2. Third party cookies are a bit scary as you're sharing your information with all your connecting websites (Google Analytics only relies on 1st party cookies).

For WordPress Users:

  • Download Cookie Notice by dFactory (there are many plugins that do the same thing, but this seems to be the easiest most reliable one right now as it allows you to customise your cookie notice to fit the style and layout of your WordPress website.)
  • In your WordPress Dashboard, go to Plugins and click Add New. Select the plugin you've just downloaded and click Activate.
  • Go to Settings > update the Message box with We or I according to whether you’re single person or team business, and you can even customise the OK button (like our client Parrot & Pineapple did) to suit your branding!
  • Scroll down until you see Position and select Top or Bottom, depending on whether you want the notice to appear at the top or bottom of the site.
  • Select Colors > Text - choose the hex code to match your branding and the same for Bar colour.
    Click Save Changes.

For Squarespace Users:

  • In the Home Menu, click Settings, click Advanced, and then click Code Injection.
  • Add the following code to the Header Code Injection box:

<script type="text/javascript"> Static.EU_COOKIE_POLICY = "top-left"; </script>

  • To replace the sample text in the banner, use this snippet and replace the message:

<script type="text/javascript">

Static.EU_COOKIE_POLICY = "top-left"

Static.EU_COOKIE_TEXT = "We use cookies to help us improve, promote, and protect our services. By continuing to use the site, you agree to our cookie policy"

Static.EU_COOKIE_BUTTON_LABEL = 'Continue'


The default styling on Squarespace isn’t too pretty, and so if you want to get a custom styling for your cookie notice then you'll need to contact a web designer.

So, you’ve now had your eyes opened to the magic that is Google Analytics, you’ve created an account and installed your tracking code to your website. You’ve also installed a Cookie Notice to your site. Amazing!

UPDATED 2018: Since GDPR regulations came into play in May 2018, you'll need to link to your Cookie Policy in your Cookie Notice. There's a box to add a link to this in the Cookie Notice plugin. You need to consult a lawyer regarding the wording (we love Heather at Stanford Gould) as it may be part of your privacy policy for your site.

All this talk of cookies has made me hungry. Grab a cookie and stick the kettle on.

Until next time!