← Back to library
consent.html
Open full screen ↗ This is the actual page the prompt produces — scroll and click inside it.

About this one

Reject must be as easy as accept, or the consent is not valid under GDPR. This spec builds it that way.

The prompt

Build a cookie consent banner.

PLACEMENT
Fixed to the bottom, full width, with padding-bottom: calc(1rem + env(safe-area-inset-bottom)). Above any bottom navigation. Do not use a full-screen modal that blocks the page — the visitor has not agreed to anything yet, including being interrupted.

CONTENT
One sentence stating what is stored and why. A link to the cookie policy. Then three controls of equal visual weight: Accept all, Reject all, and Manage.

Critical: Reject must be exactly as prominent as Accept — same size, same contrast, same position in the flow. A greyed-out reject button next to a bright accept button is a dark pattern and invalidates the consent it collects.

MANAGE PANEL
Expands in place rather than opening a new modal. Lists categories with individual toggles: Necessary (on, disabled, with an explanation of why), Analytics, Marketing. Everything except Necessary defaults to off. A save button applies exactly what is toggled.

BEHAVIOUR
Store the decision with a version number and a timestamp. Re-ask when the version changes. Fire no analytics or marketing scripts until consent exists — loading the script first and asking after defeats the entire point.

RULES
Fully keyboard operable, focus trapped inside the banner while it is open. Under prefers-reduced-motion, appear without the slide-up.

More in Landing pages

Install 3D Website Full screen, opens straight from your home screen.