Calculate contrast ratios between text and background colors according to Web Content Accessibility Guidelines (WCAG 2.1). Ensure universal readability for all users.
This paragraph renders live with your chosen foreground text color over your background color. Notice how effortless or strained your eyes feel while reading.
Reserved for AdSense unit (tool) • Responsive & Non-intrusive
Contrast ratio is calculated using relative luminance (L), defined as the relative brightness of any point in a colorspace normalized to 0 for black and 1 for white. The official W3C formula is:
Where L1 is the relative luminance of the lighter of the colors, and L2 is the relative luminance of the darker of the colors. The resulting ratio ranges between 1:1 (zero contrast, e.g. white text on white background) and 21:1 (maximum contrast, black on white).