Skip to content

Freelance

70% of websites fail the contrast test

I came across a number that surprised me a little: the vast majority of websites fail the contrast test. And not because devs don't care!

I came across a number that surprised me a little: the vast majority of websites fail the contrast test.

And not because devs don't care! It's just the kind of detail that slips through on a button or a placeholder and ends up making a page painful to read...

And it's not just an impression. Across the million most visited home pages, WebAIM found low-contrast text on 83.9% of them. And that number barely moves from one year to the next.

So what is it, exactly? The difference in brightness between your text and its background. The WCAG standard asks for at least 4.5:1 for normal text and 3:1 for large text.

And who does it bother? Far more people than you would think: older people whose eyesight is fading, colour-blind people, and you, on your phone, in full sunlight.

The usual suspects? Not out of carelessness, just the small details: a light grey placeholder, a button in the brand colours, a caption or some secondary text. One at a time, they get by. Put together, the page becomes painful to read.

Good news though: CSS can now pick the text colour by itself, with color: contrast-color(var(--brand)). The browser picks black or white depending on what reads best on the background. One line, no library. Check browser support before using it everywhere.

Your turn: test your site in 2 minutes. Chrome's Lighthouse tab, or any online contrast checker, instantly shows you the text that is too pale.

What about you, do you think about it when you pick your colours?

Sources: WebAIM Million 2026, Smashing Magazine, May 2026.

TopicsAccessibilitéCSSDeveloppementWeb