WCAG Contrast Checker
Check color contrast ratios to ensure your design meets WCAG 2.1 accessibility standards. Enter foreground and background colors to test compliance.
Preview
Contrast Ratio & Compliance
How It Works
What is Color Contrast?
Color contrast is the difference in perceived brightness between foreground (text) and background colors. The contrast ratio ranges from 1:1 (no contrast) to 21:1 (maximum, black on white). Sufficient contrast ensures text is readable for everyone, including people with visual impairments.
WCAG 2.1 Compliance Levels
- WCAG AA (Minimum): Required for most websites
- Normal text: 4.5:1 contrast ratio
- Large text (18pt+ / 14pt+ bold): 3:1 contrast ratio
- WCAG AAA (Enhanced): Higher standard for optimal accessibility
- Normal text: 7:1 contrast ratio
- Large text (18pt+ / 14pt+ bold): 4.5:1 contrast ratio
How the Ratio is Calculated
The contrast ratio is derived from the relative luminance of each color using the WCAG formula:
(L1 + 0.05) / (L2 + 0.05), where L1 is the lighter color's luminance and L2 is the darker.
Luminance is calculated by converting sRGB values to linear light, then weighting by human perception
(red 21.26%, green 71.52%, blue 7.22%).
Why Contrast Matters
- Vision impairments: Low vision, color blindness, age-related changes
- Environmental factors: Bright sunlight, screen glare, low-quality displays
- Legal requirements: ADA, Section 508, EU accessibility directives
- Better UX: Improves readability and usability for all users
Large Text Definition
WCAG defines large text as 18pt (24px) or larger for regular weight, or 14pt (18.5px) or larger for bold text. Large text has lower contrast requirements because it is inherently easier to read.
Related Utils
Feedback
Help us improve this page by providing feedback, and include your name/email if you want us to reach back. Thank you in advance.
Sending...
Feedback sent. Thank you!
Error occurred!
-
-
-
-
-
-
-
- ABI Encoder / Decoder
- Block Estimator
- Calldata Cost
- CREATE2 Address
- ENS Availability
- ENS Cost Estimator
- ENS Lookup
- ENS Namehash
- ENS Record Viewer
- ENS Subname Explorer
- ERC-20 Unit Converter
- Gas Estimator
- HD Wallet Derivation
- Merkle Tree Visualizer
- 4-Byte Selector Lookup
- Solidity Storage Layout
- Transaction Decoder
- Vanity Address Estimator
- Wallet Address Validator
- Wei/Gwei/Ether Converter
-
-
-
-
-
- API Response
- ASCII Table
- Code Bug Detector
- Code Explanation
- CSS Beautifier
- Env Parser
- GraphQL Query
- Syntax Highlight
- HTML Beautifier
- JS Beautifier
- JSON Formatter
- JSONPath
- JWT Decoder
- JS keyCodes
- API Lorem Ipsum
- RegExp
- Regex Library
- Semver Compare
- SQL Beautifier
- TOML Formatter
- Code Unminifier
- XML Beautifier
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Amortization
- Break-Even
- Compound Interest
- Crypto Profit/Loss
- Debt Payoff
- Discount
- Effective Interest
- Emergency Fund
- Inflation Calculator
- Simple Interest
- Invoice Calculator
- IRR Calculator
- Mortgage
- NPV Calculator
- Portfolio
- Profit Margin
- Rent vs Buy
- Retirement Calc
- ROI Calculator
- Salary vs Hourly
- Savings Goal
- Tax Calculator
- VAT
-
-
-
-
-
-
-
-
-
-
-
-
- Equation Solver
- Exponent Calculator
- Factorial Calculator
- Fibonacci Sequence
- Fraction Calculator
- Fraction Simplifier
- GCD Calculator
- GCD/LCM
- Least Common Multiple (LCM) Calculator
- Logarithm Calculator
- Magic Square
- Matrix Calculator
- Number Base Converter
- Pascal's Triangle
- PDE Solver
- Prime Checker
- Prime Factorization
- Roman Numbers
- Scientific Notation
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Broken Link Checker
- Canonical URL Checker
- Core Web Vitals Checker
- Favicon
- Heading Structure
- Keyword Density
- Meta Tags
- Mobile-Friendly Test
- Open Graph Tags
- Page Load Time Analyzer
- Redirect Checker
- robots.txt
- Schema Markup
- SEO Optimized Checklist
- XML Sitemap
- Time on Page Tracker
- Page Title & Desc.
- Twitter Card Generator
-
-
-
-
-
-
- Acceleration
- Substance Amount
- Angle
- Area
- Astronomical
- Base Converter
- Capacitance
- Electric Charge
- Data Transfer
- Data Storage
- Density
- Energy Converter
- Force Converter
- Frequency Converter
- Fuel Economy
- Illuminance
- Inductance
- Length / Distance
- Power
- Pressure
- Electrical Resistance
- Time
- Speed
- Temperature
- Viscosity
- Volume
- Weight
-
-
-
-
-