Color contrast checker
Check WCAG color contrast ratios for accessibility
Normal text (16px): The quick brown fox jumps over the lazy dog
Large text (18px bold): The quick brown fox jumps over the lazy dog
- Select your foreground (text) color using the color picker or hex input
- Select your background color
- The contrast ratio is calculated automatically
- Check the WCAG compliance results for normal and large text
- Use the preview to see how the colors look together
- Aim for at least AA compliance (4.5:1 for normal text, 3:1 for large text)
Colors:
Foreground: #000000 (black)
Background: #ffffff (white)
Result:
Contrast ratio: 21:1
Normal text AA: Pass ✓
Normal text AAA: Pass ✓
What is color contrast ratio?
Contrast ratio measures the difference in luminance between two colors. It ranges from 1:1 (no contrast) to 21:1 (maximum contrast, black on white).
What is WCAG?
WCAG (Web Content Accessibility Guidelines) are standards for making web content accessible. They define minimum contrast ratios for text readability.
What ratio should I aim for?
For normal text, aim for at least 4.5:1 (AA) or 7:1 (AAA). For large text (18pt+ or 14pt+ bold), 3:1 (AA) or 4.5:1 (AAA) is acceptable.
Why does contrast matter?
Good contrast ensures text is readable for everyone, including people with visual impairments, color blindness, or viewing in bright sunlight.
Can I use this for UI elements?
Yes, WCAG also requires 3:1 contrast for UI components and graphical objects. Use this tool to verify buttons, icons, and form controls.