Why this wireframe works | Cookie banner with toggles
People choose by category without opening another screen
Because the category switches are inside the bar, even someone who only wants to allow analytics can finish choosing the first time.
Necessary cookies say “Always on” and cannot be switched
Cookies the site needs to work are labeled in words as impossible to turn off. It is clear at a glance what can and cannot be chosen.
Reject all and Accept all carry equal weight
Matching buttons sit at both ends, with “Allow selected” between them. Every way of choosing takes the same effort.
Common mistakes | Cookie banner with toggles
Switches start in the on position
If analytics and advertising switches start on, people who save without touching anything are counted as having allowed them. Start everything except necessary cookies off.
On and off differ only by color
The shade of a switch alone is hard for some people to read. Add the words “On” and “Off”, and use role=”switch” and aria-checked so screen readers announce the state too.
Category names alone do not say what cookies are for
“Functional” or “Analytics” alone gives people little to go on. Put explanations that do not fit in the bar behind “Learn more about cookies”.
Too many categories, and the bar covers half the screen
With five or more categories, the bar grows and hides the content. When there are many, move them to a cookie settings panel.
FAQ | Cookie banner with toggles
How many categories can fit in the bar?
Three or four, which fit in one row on desktop and in two columns and two rows on mobile. For more than that, or to show a list of recipients for each category, use the cookie settings panel.
Should the “Allow selected” button stand out?
Making just one of the three stand out looks like steering people toward that choice. Give Reject all and Accept all the same look and make Allow selected an outlined button, for example, so every option is easy to press.
Is a cookie consent bar always required?
Whether you need consent, and how much you need to explain, depends on the cookies you use, the data sent to outside services, and the rules where your users are. Examples include GDPR and the ePrivacy Directive in the EU, US state laws such as CCPA/CPRA, and Japan’s rules on sending user data to third parties. This pattern is an example of how to build the screen; for legal decisions, check with a specialist as needed.











