Free tool

Cookie banner generator

Configure your banner and get a self-contained HTML/CSS/JS snippet (no dependency) to paste into your site, whatever its framework.

Indicative template, not legal advice. Adapt the wording and the categories to what your site actually does (only tick a category if you genuinely set that kind of cookie) before going live.

The banner alone is not enough.It keeps the visitor's choice for about 6 months, exposes it in window.zkyCookieConsent as soon as each page loads and fires the zkyCookieConsentChanged event on every choice. It is up to you to wire your third-party scripts (Google Analytics, advertising pixels, etc.) to it: read window.zkyCookieConsent on load, listen to the event, and only load a tracker if its category is accepted (example at the top of the snippet). On refusal, the banner deletes common cookies already set (_ga, _ga_*, _gid, _gcl_*, _fbp, _fbc) on the domain and its parent domains; add those of other tools yourself. Without that wiring, the banner is displayed but blocks nothing on its own.

Withdrawing consent.The snippet adds a small floating "Manage my cookies" button, visible once a choice has been made, which reopens the settings with the boxes ticked according to the stored choice. You can also call window.zkyOpenCookieSettings() from a link in your footer.

Generated snippet

No category ticked: no banner is generated. Cookies strictly necessary for the site to work (session, cart, security, remembering a choice) are exempt from consent, so no banner is required for them. Tick a category as soon as you add a non-exempt audience measurement tool or advertising.

This site only uses cookies that are necessary for it to work, including one to remember that you have read this message. We also measure our traffic with a tool we host ourselves, without cookies and without storing your IP address. No advertising, no third-party trackers. Learn more about privacy