Color Contrast Checker
Calculate WCAG contrast ratio for two opaque sRGB colors.
Your workspace
Processed in your browserThis utility calculates the contrast ratio between two colors to help you ensure your designs meet Web Content Accessibility Guidelines (WCAG). It helps you decide if your text will be readable against a specific background.
How to check contrast
- Input the HEX code for your text color and the HEX code for your background color.
- Review the generated contrast ratio and the pass/fail status for standard and large text accessibility levels.
Understanding accessibility standards
The tool evaluates contrast against WCAG AA (4.5:1 ratio for normal text) and AAA (7:1 ratio) standards. A higher ratio indicates better readability. If a combination fails, consider adjusting the lightness or saturation of your colors to improve the contrast.
Check a standard pair
Text #000000, Background #ffffff
21:1 ratio (Passes all)
Questions about contrast checking
What does the contrast ratio number mean?
The ratio represents the difference in luminance between the two colors. A ratio of 1:1 means no contrast, while 21:1 is the maximum possible contrast (black on white).
Why does my color combination fail?
A failure usually means the colors are too similar in brightness. To fix this, you can darken the text color or lighten the background color to increase the luminance difference.
Continue your workflow
Explore more tools in this category for your next step.
Gradient Contrast Checker
Sample 101 evenly spaced positions along an sRGB two-color gradient and report the lowest text contrast at those samples.
Palette Contrast Matrix
Calculate WCAG relative-luminance contrast ratios for every pair of entered colors.
Color Blend Calculator
Mix two colors by a chosen proportion using sRGB channels or linear-light RGB.
Color Blindness Simulator
Apply approximate protanopia, deuteranopia or tritanopia RGB matrices to an uploaded image; simulations do not diagnose vision.