Product support

Visit this product's website for support.


Small and simple plugin to cope with GDPR on your website.


  • Easily edit cookies groups and add JS code to be executed if the group is allowed
  • Simple Cookies bar component with optional modal popup
  • Manage cookies component to be used on GDPR pages
  • Fully translatable (with Rainlab Translate plugin)
  • Optional component output styling (Plain HTML, Bootstrap 3, Bootstrap 5)
  • Import and export your prefered settings (or use default presets)
  • Option to limit scripts execution to specific pages (URLs)
Cookies groups settings

Small GDPR

Simple plugin to cope with GDPR


GitHub clone into /plugins dir:

git clone https://github.com/jan-vince/smallgdpr

OctoberCMS backend

Just look for 'Small GDPR' in search field in:

Settings > Updates & Plugins > Install plugins


Settings > Administrators

You can set permissions to restrict access to Settings > Small plugins > Small GDPR and to messages list.

Quick start guide


  • Install plugin.

  • Go October's settings page and click on GDPR > Cookies.

    • Go to tab Import and click button Import default settings.
    • Go to tab Cookies, add your JS code to cookies group as you need.
  • Go to CMS part of October.

    • Add new Layout (or use your existing)
    • Add component Small GDPR > Cookies bar (inside of your body tag).
  • Go to CMS part of October.

    • Add new Page with URL /gdpr
    • Add component Small GDPR >┬áManage cookies (inside any of your tags)

Do not forget to add {% scripts %} tag to your layout page just before closing body tag! More info in October docs.

  • Open your website - cookies bar should be visible :)


Tab: Cookies groups

The main idea is to create groups of cookies with JS scripts that you want to run on your website.


When turned on users cannot disable these groups in Manage cookies component and scripts will be always executed.

Default enabled

Scripts in these groups will run without explicit user concent but can be disabled by user (in Manage cookies component).

Be careful not to violate your local laws!


You can add one or more scripts to selected group

Custom JS code or files

You can add your own JS code and/or files to be executed when a cookies group is allowed (or required).

You can optionally limit scripts execution to production mode.

Run only in production

Script wil be executed only in production environment.


This scripts will never be executed

Run on specific pages

You can limit scripts execution to specific pages URLs.

Tab: Cookies bar

You can edit title and content of cookies bar.

If you want, you can select from pre-defined CSS styles.


You can add one or more buttons to your cookies bar.

Allow all cookies

When turned on, click on this button will set all cookies groups enabled.

Usefull for "Allow all" button on Cookies bar.

Note: Users can change cookies settings later on CMS page with Manage cookies component (like /gdpr) if you create one.

Open modal window

When turned on, click on this button open modal window with list of cookies group.

Currently supported only for Boostrap 3 UI style (can be set on tab Settings).

Tab: Manage cookies

Just add title and content and those will be shown above cookies groups listing in Manage cookies component.

Tab: Settings

Few general settings to be set.

Cookies expiration

Number of days for cookies to live in browser.

UI style

Change formating of output HTML code.

Tab: Import

You can import settings presets from Media your own path or default plugin preset (if you leave all empty).

You have to use YAML format.

Note: Try Export first to get idea of an import file structure.

Tab: Export

You can export current settings data to configuration file and use it as a backup or template for other sites.


Cookies bar

Should be used in your Layouts or Pages.

Hide Cookies bar

If you need to hide Cookies bar on specific Page or Layout, you can use View Bag on your Page this way:

hideCookiesBar = 1

Manage cookies

Put this component to your page with details about privacy (like /gdpr or /cookies).

Manage cookies component can be also added as a snippet to Static Page

Users will be able to change cookies settings.


With component Cookies bar or Manage cookies you can access cookies settings in your Twig code like this:

{% if sgCookies.necessary %}
{% endif %}

My thanks goes to:
OctoberCMS team members and supporters for this great system.
Brooke Cagle for her photo.
Font Awesome for nice icons. OFFLINE for inspiration from his GDPR plugin

Created by Jan Vince, freelance web designer from Czech Republic.

  • Found the plugin useful on 1 Feb, 2022

    Very good plugin, complete and easy to set up. Nice work, thanks

  • author

    Replied on 1 Feb, 2022

    Hi and thank you!

  • Found the plugin useful on 20 Mar, 2021

    This is a really useful solution for modern websites. Thanks and respect to the author.

  • author

    Replied on 20 Mar, 2021

    Thanks, i appreciate it!


  • Found the plugin useful on 16 Jul, 2020

    It's already a must have plugin! The ability to manage cookies' categories independently is such a great feature.

    Working on an implementation using TailwindCSS, I was afraid about the support but really well-surprised of the good design of the code (at least the components partial, didn't look yet the PHP code :) ).

    I will share my TwCSS implementation in this comment in few days for those who want.

    Thanks Jan Vince for the work!

  • author

    Replied on 17 Jul, 2020

    Thank you :)

    Best regards,



Added option to run JS script after Accept-all Button click

May 13, 2023


Strict variables fix (thanks @SamBrishes)

Mar 29, 2023


OC3 compatibility

Nov 09, 2022


Added option to pre-check cookies list items in modal window

Sep 21, 2022


Fixed css

Sep 21, 2022


Updated preset

Sep 17, 2022


Fixed Twig code for OC3

Sep 17, 2022


Fixed version yaml for OC3

May 21, 2022


Added Finnish language (thanks mediaclinic)

Mar 01, 2022


Updated default presets with Google Analytics code to run without consent with disabled storage

Feb 06, 2022


Added option to require cookies consent for each web site language separately

Feb 06, 2022


Fixed bug in Bootstrap 5 modal form template

Feb 06, 2022


Fixed bug in JS

Jan 18, 2022


Updated presets texts

Jan 16, 2022


Updated css for Bootstrap box UI

Jan 13, 2022


Fixed cookies bar buttons function

Jan 13, 2022


Added Reject all button onption, updated import presets

Jan 10, 2022


Updated css styles for topline strip in container

Sep 07, 2021


Fixed css styles for topline strip in container

Sep 07, 2021


Added option to display top strip in Bootstrap container

Sep 07, 2021


Updated default presets with new GA code

Sep 01, 2021


Fixed modal hide function

Mar 19, 2021


Fixed versions numbering

Mar 19, 2021


!!! If you edited default components markup (or you use only parts of it), please check if everything works after update. If you use plugin as is, you should be fine :)

Mar 19, 2021


Fixed external URL handling with cookies bar buttons

Mar 19, 2021


Fixed cookie lifetime function

Mar 19, 2021


Added Slovak translation, fixed Czech translation

Feb 01, 2021


Added optional Cookies bar strip CSS styles

Jan 30, 2021


Updated Bootstrap 5 modal support (thanks evwerkz)

Jan 04, 2021


Added Russian and German language (thanks evwerkz)

Dec 21, 2020


Fixed HTML attributes field localization in Settings

Nov 24, 2020


Added option to specify pages to run scripts on

Nov 19, 2020


Changed settings for import (added second btn for import default settings)

Nov 19, 2020


Changed buttons HTML attributes field to prevent naming collision

Nov 03, 2020


Added Twig support for Translate plugin (thanks evwerkz)

Aug 07, 2020


Fixed localization

Aug 05, 2020


Moved modal help-block div from label tag (to be HTML5 valid)

Jul 31, 2020


Fixed CookiesSettings model

Jun 29, 2020


Added sgCookies to Cookies Manage component (for case when you do not want to use Cookies Bar in your layout or page)

Jun 27, 2020


Fixed components file name case

Jun 25, 2020


Updated translation and docs.

Jun 23, 2020


!!! Cookies JS code placed in code window now requires <script> tags to be present! Please check your code.

Jun 23, 2020


Fixed folders and models name case

Jun 23, 2020


Fixed migration not working on new installs

Jun 23, 2020


Removed forgotten dump

Jun 23, 2020


Extended import tab to be able to use Media, own path or default preset file

Jun 23, 2020


Added option do have more scripts and files in scripts group (old scripts data are automatically migrated to the new structure)

Jun 23, 2020


Fixed import function

Jun 22, 2020


Import file can be now selected from Media panel

Jun 22, 2020


Added export settings function

Jun 22, 2020


Changed fields order in form

Jun 22, 2020


Added option to run JS only in production mode

Jun 22, 2020


Updated styling, removed unnecessary styles

Jun 22, 2020


Added optional cookies group script file to be executed

Jun 21, 2020


Updated hideCookiesBar check to support Static Pages

Jun 21, 2020


Added option to hide Cookies bar on specific Page or Layout with View Bag property

Jun 21, 2020


Fixed values checks in CookiesSettings

Jun 21, 2020


Added Default enabled option for cookies groups for cookies to be executed without explicit consent

Jun 21, 2020


Removed unnecessary line in Manage cookies component

Jun 21, 2020


Added Static Pages snippet for Cookies manage component

Jun 20, 2020


Removed option Default active

Jun 20, 2020


Fixed default active cookies group to be active even without explicit consent

Jun 20, 2020


Fixed default EN preset

Jun 20, 2020


Fixed sgCookies array

Jun 20, 2020


Fixed scripts

Jun 20, 2020


Fixed sgCookies array to reflect required cookies group state

Jun 20, 2020


Updated default presets and README

Jun 20, 2020


Added settings in modal window

Jun 20, 2020


First version of Small GDPR

Jun 19, 2020