Roughly one man in twelve has some form of colour vision deficiency, and the most common kind collapses exactly the pair — red and green — that interfaces use for success and error. Here is what to do about it, and why adding an icon is only half the fix.
Success criterion 1.4.1 Use of Colour is short and frequently misread. It says colour must not be used as the only visual means of conveying information, indicating an action, prompting a response, or distinguishing a visual element.
Note what it does not say: it does not require you to avoid colour, and it does not require a text alternative for every coloured element. It requires a second channel. That can be text, an icon, a shape, a pattern, position, or an underline.
Deuteranomaly — reduced sensitivity to green — is the most common form, followed by protanomaly affecting red. Together they account for the large majority of colour vision deficiency. Tritanopia, affecting blue/yellow discrimination, is rare.
The practical consequence is unglamorous and specific: a green "success" dot and a red "error" dot can look like the same muddy brown dot. The user sees that something changed, and cannot tell which.
The right-hand panel approximates what a user with deuteranopia sees. The two dots are now nearly identical — but the words still work.
The standard advice is "add an icon." That helps, but icons are frequently too small, too abstract, or too similar to each other to carry the meaning alone. The robust pattern is:
Where space is tight, at minimum ensure the states differ in lightness. Colour-blind users retain luminance perception almost intact, so a dark red and a light green are distinguishable where two equally-bright colours are not. This is also why grey-scale testing catches so many real problems.
Error states are where colour-only design does the most damage, because the user has to find the problem before they can fix it.
Using a red-tinted placeholder text to indicate an invalid field fails twice over: placeholder text is usually below 4.5:1 by design, and it disappears the moment the user starts typing — removing the only signal you provided.
Charts are the hardest case, because colour is doing real work distinguishing series. Three techniques that hold up:
Sequential scales deserve a note: a rainbow scale (blue → cyan → green → yellow → red) is not monotonic in perceived lightness, so it misrepresents ordering for everyone. Use a single-hue ramp that gets uniformly lighter or darker.
Two things break when a light theme is inverted mechanically:
#000000 with #FFFFFF text produces halation — letters appear to bleed. Use a near-black surface and slightly off-white text.Also note that dark mode does not relax contrast requirements. A #767676 grey that scores a comfortable 4.54:1 on white drops to 4.12:1 on #121212 — short of the 4.5:1 AA threshold. Colours that pass on white often fail on dark, so re-test rather than assume symmetry.
If you remove the default focus ring, you must provide a replacement that meets 3:1 against the adjacent background. WCAG 2.2 adds criteria on focus appearance — the indicator needs sufficient area and must not be entirely hidden by other content.
A reliable pattern: a two-tone ring — a light inner ring and a dark outer ring — so the indicator is visible on both light and dark surfaces without you having to detect the background.
This guide covers the visual-design side of colour accessibility. It is educational material, not a compliance certification — verify against the current W3C recommendation and any standard that applies to you.