Color Contrast Ratio Calculator
Check the contrast ratio of two colors for accessibility.
Result
How to use
- Enter your values in the fields above.
- Press Calculate to see your result instantly.
- Use the Share button to copy a link to your result.
About this calculator
This calculator computes the WCAG contrast ratio between two colors using (L1 + 0.05) / (L2 + 0.05), where L1 and L2 are the relative luminances of the lighter and darker colors, each derived from the sRGB channel values via the WCAG's gamma-corrected luminance formula. The result ranges from 1:1 (identical colors) to 21:1 (pure black on white), and is checked against the Web Content Accessibility Guidelines thresholds — 4.5:1 for normal text and 3:1 for large text at AA level, 7:1 and 4.5:1 respectively for the stricter AAA level.
Web designers, front-end developers, and accessibility auditors use this to ensure text and UI elements meet legal and usability accessibility standards (WCAG 2.1, ADA, Section 508 compliance) for users with low vision or color blindness. Enter two hex colors to get the contrast ratio and pass/fail status.
Was this helpful?
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
No calculators found
Comments (0)