Fails
Grey delivery note on white
Live preview
.delivery-note { font-size: 1rem; color: #999999; background-color: #ffffff;}
#999999 on white is 2.85:1. Text at 16px is normal size, so it needs at least 4.5:1.
Perceivable · 1.4 Distinguishable
Text and images of text need a contrast ratio of at least 4.5:1 against the background, or 3:1 for large text of at least 18pt, or 14pt bold. Incidental text, such as text in disabled controls, pure decoration or a picture with other significant content, and logo text are exempt.
Live demo
The same task, done two ways: switch between the version that passes and the one that fails, or put them side by side. Everything in the box is live, so try it with a keyboard, a pointer or a screen reader.
Switch between Passes and Fails, then pick your own text and background colors. Text at this size needs a ratio of at least 4.5:1.
Your parcel left our warehouse this morning. It should arrive on Thursday between 9 am and 1 pm.
Your parcel left our warehouse this morning. It should arrive on Thursday between 9 am and 1 pm.
The tools follow the version you last used.
What happened
Why it passes
Dark grey text on white is 10.31:1. The delivery time is easy to read, even on a dim screen or with low vision.
Why it fails
Light grey text on white is 2.54:1. Many people, including older readers and anyone using a phone in bright sunlight, struggle to read the delivery time.
Examples
Five examples, each one running: the usual ways this criterion fails, and code that passes. Listen to them, measure them, or copy the code.
− #999999 + #767676
Fails
Live preview
.delivery-note { font-size: 1rem; color: #999999; background-color: #ffffff;}
#999999 on white is 2.85:1. Text at 16px is normal size, so it needs at least 4.5:1.
Passes
Live preview
.delivery-note { font-size: 1rem; color: #767676; background-color: #ffffff;}
#767676 on white is 4.54:1, just above the minimum. Setting the background as well as the text color keeps the pair together if a reader's default background is different.
− #f97316 + #c2410c
Fails
Live preview
.add-to-cart { font-size: 1rem; font-weight: 600; color: #ffffff; background-color: #f97316;}
White on #f97316 is 2.80:1. A 16px label is not large text, so it needs 4.5:1, and it does not even reach the 3:1 allowed for large text.
Passes
Live preview
.add-to-cart { font-size: 1rem; font-weight: 600; color: #ffffff; background-color: #c2410c;}
White on #c2410c is 5.18:1, so the label meets 4.5:1 and the button keeps its orange brand color.
Passes
Live preview
.hero { color: #ffffff; background: linear-gradient(rgb(0 0 0 / 0.6), rgb(0 0 0 / 0.6)), url("beach.jpg") center / cover;}
The 60% black layer turns even a pure white patch of the photo into #666666, so the white headline never drops below 5.74:1.
Why it matters
People with low vision, color vision deficiencies or age-related loss of contrast sensitivity can read text that would otherwise blend into its background.
W3C: Understanding 1.4.3Level AA
Level AA is the level most laws and policies require.
Where it is required
Required where the law names WCAG 2.0 or later at this level: the United States, Canada, the European Union, the United Kingdom, France, Germany, Italy, Spain, the Netherlands, Ireland, Norway, Switzerland, India, Japan, Australia, New Zealand and Israel.
How to test
A few concrete steps. Automated tools find some failures; most need a person.
Common failures