About this plugin
SunnyGDPR provides a simple, ultra-fast, and compliant cookie banner for your WordPress website.
Unlike heavy, resource-intensive GDPR “all-in-one” plugins that try to catch, block, and analyze every single request on the fly, SunnyGDPR follows a smart, developer-friendly logic:
As a site owner or developer, you already know exactly which scripts require consent before firing (such as Google Analytics, Yandex Metrika, Facebook Pixel, or ad tracking codes). 1, SunnyGDPR introduces a dedicated field in the admin settings where you can paste these conditional scripts.
How it works:
- Before consent: Tracking codes and analytical scripts remain completely omitted from the HTML output.
- Upon consent: The user accepts the GDPR terms, a consent cookie is written for 1 year, and the page automatically reloads to inject and execute the approved scripts.
- If declined: The user is redirected to an isolated static HTML page ( cookie-declined.html ), preventing unnecessary server and database queries.
No overhead, no bloat, and zero impact on your site speed.
Key Features
- Lightweight & Blazing Fast: Built with pure Vanilla JS and clean CSS without external dependencies.
- Conditional Script Output: Inject tracking, analytics, or marketing scripts only after explicit user consent.
- One-Year Consent Cookie: Remembers user choice for 365 days ( sunnygdpr_consent ).
- Autonomous Decline Handler: Static HTML page for declined users to save server resources.
- Fully Customizable: Easily edit consent texts, button labels, and code snippets from WP Admin.
- Clean Uninstall: Automatically removes all stored settings upon uninstallation.