Multilingual cookie banner: languages, detection and translations
How to show a cookie banner in the visitor's language: page or browser language, what to translate, keeping the meaning equal across languages, and testing.A cookie banner should speak the language the visitor reads the site in. Consent under the GDPR must be informed and requested in clear and plain language, and a banner in a language the visitor does not understand informs nobody. In practice, match the page language on sites with translated pages, fall back on the browser's preferred languages elsewhere, translate every string including the preferences panel and the cookie table, and keep the buttons equal in every language, because a translation can quietly turn "Reject all" into something weaker.
Why does language matter legally?
Article 7(2) of the GDPR requires a request for consent to be presented in an intelligible and easily accessible form, using clear and plain language, and article 12(1) applies the same standard to all information given to people. The EDPB's consent guidelines say the information must be understandable for an average person, not only for lawyers. A visitor in Lisbon reading an English-only banner on a Portuguese-language shop is not in a position to give informed consent.
Page language or browser language?
There are three ways to choose the banner language:
| Method | How it works | Best for |
|---|---|---|
| Page language | Read the lang attribute of the page or the language segment of the URL | Sites with translated pages (/fr/, /de/) |
| Browser language | Read navigator.languages or the Accept-Language header | Sites in one language with an international audience, or apps |
| Visitor choice | A language switcher inside the banner | Mixed audiences, border regions |
MDN describes navigator.languages as the visitor's preferred languages in order of preference, generally matching the Accept-Language header. It also notes that Safari, and Chrome in incognito mode, may expose only one language to reduce fingerprinting, so browser detection is a best guess.
On a site with translated pages, page language is the safer default: the visitor chose that version, and the banner should match the content around it. On a single-language site, showing the banner in the visitor's browser language helps them understand the choice, even if the rest of the page is in another language.
What has to be translated?
Everything a visitor reads before or while choosing:
- the first layer: title, text, button labels;
- the preferences panel: category names and descriptions, toggle labels, the Save button;
- the cookie table: purpose and duration descriptions (cookie names stay as they are);
- the US opt-out notice and the "Do Not Sell or Share" link, if you show them;
- embed placeholders ("This video is hosted by YouTube...");
- the cookie policy and privacy policy the banner links to.
The cookie policy is easy to forget. A banner in Spanish that links to an English-only policy leaves the details untranslated.
How do you keep the meaning equal?
Translations drift. Three checks for each language:
- Button parity. "Reject all" must stay a clear refusal of equal weight: "Tout refuser", "Alle ablehnen", "Rechazar todo", "Rifiuta tutto". Watch for translations that soften it into "Continue without" or "Settings".
- Length. German and Finnish labels are often longer than English. Check that both buttons still have the same size and that nothing wraps into an uneven layout, especially on phones.
- Purposes. Translate the purposes, not just the word "cookies". "Mesure d'audience" or "Reichweitenmessung" for analytics, "publicité" or "Werbung" for marketing, so the visitor knows what they accept.
Use a native speaker or a professional translation for the main languages. Machine translation is a reasonable first draft, but legal wording is where it makes mistakes.
Accessibility and the lang attribute
If the banner's language differs from the page's, set the lang attribute on the banner's container so screen readers switch pronunciation. WCAG 2.2 success criterion 3.1.2, Language of Parts, asks that the language of each passage can be determined by software. The accessible cookie banner guide covers focus, contrast and keyboard use.
What about the consent record?
Record the language the banner was shown in with each choice. If a visitor claims they did not understand the request, the log shows the text and language they saw, together with the banner version. Keep previous versions of each translation when you change them.
Which languages do you need?
Start from where your visitors are, not from a list of all languages. Your analytics shows the countries and browser languages that send traffic; cover the languages of the countries where you need opt-in consent first. For the EU, the cookie banner requirements by country show which regions need the full banner.
Ready-made translations
Most consent tools ship translations. Cookiequiet's banner comes in 24 languages (English, French, German, Spanish, Italian, Portuguese, Dutch, Polish, Swedish, Danish, Norwegian Bokmål, Finnish, Czech, Slovak, Hungarian, Romanian, Greek, Bulgarian, Croatian, Slovenian, Estonian, Latvian, Lithuanian and Turkish), picked from the visitor's browser languages, with every string editable per language. It follows the browser rather than the page, so on a site with translated pages, check that the result suits your audience. Setup is one script tag before your other scripts, with Reject all on by default; the text examples guide has wording to start from.