How To Add A Cookie Notice To Your WordPress Blog For FREE

2 Comments . 19 January 2021  .  minute read

Disclosure: This article contains affiliate links. When you click these links and make a purchase, I may get a small commission. It won’t cost you anything, but it helps me to run this site.  Find out more.

I would like to share with you my new favourite plugin for cookie notices and consent.

Cookie notice showing on wordpress blog

As you might know, I am always on the lookout for lightweight plugins that don’t add bloat and do the job they set out to do sweetly and efficiently.

I love this one, because it is so easy to set up, and, well …. it just does the job!

Why you need a cookie notice plugin

In the EU it is the law that you must not save cookies to a site visitor’s browser unless they give you their permission. The same law will likely come into force in other countries if it hasn’t already, so it is just as well to comply now.

Also, you can’t be certain which country your visitors come from, so you must apply the consent to everyone.

Video – How To Add A Cookie Notice To Your WordPress Blog For FREE

Don’t have time to read? Check out my video instead.

How to install and setup the Cookie Notice plugin in WordPress

Step 1 – Install the plugin

  • Go to Plugins->Add New
  • Search for Cookie Notice and the plugin by dFactory should come up near the top
Cookie notice for GDPR and CCPA plugin by dFactory

Alternatively, download the plugin from here and then upload it to WordPress (Plugins->Add new->Upload Plugin)

If installing plugins is new to you. See my handy guide here – How to Install a WordPress Plugin.

Step 2 – Setup the plugin

Once you have the plugin installed you should find its settings under Settings->Cookie Notice.

There are quite a few things you can tweak, but the plugin very helpfully sets up some default settings which will be fine in most cases.

Here are some things you might want to tweak:

  1. The message displayed to your website visitors
  2. Add your Privacy policy link. Don’t have a privacy policy? Here is how.
  3. Change the Accepted expiry. You might want to set this to more than a month.
  4. Change the button colour.
  5. Set the option to Refuse consent
  6. Add your analytics script (see step 3)

Step 3 – Add your analytics scripts

If you use this plugin in it’s most basic form, then you are not fully compliant in terms of cookie consent.

Strictly speaking, you should not save cookies to your user’s browser unless they give consent. When they agree, only then should you save the cookie.

Fortunately, this plugin lets you add scripts such as your Google Analytics script which will only get loaded up once you have consent.

Here is how to do it for Google Analytics, the process will be the same for the Facebook pixel, or any other tracking script you have on your blog.

  1. Grab your Google Analytics tracking script. If you don’t have analytics, here is how to get it.
  2. Add it to the script box.
  3. Remove the script from elsewhere in your blog.
How to add google analytics script to cookie notice plugin

Number 3 is very important to check!

You only want to have any tracking script appear once on your blog. Otherwise, you will have double-counting occurring which can be very demoralising once you realise it has happened.

Places to check would be the Header Footer plugin if you use that, or any plugins you have installed that allow you to add scripts. Another place to check would be your theme options.

Here is more on how to check for double analytics scripts.

Proofread with Grammarly

Related posts

Did you love this post? Please share it if you did!

  • {"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}
    >