SheepDev

Contrast ratio

Contrast ratio lets you calculate contrast after alpha compositing and report WCAG thresholds in your browser.

Contrast ratio

⌂ Inputs and results stay in this browser and are not automatically stored or sent.

Waiting for input
● Live preview

Input & settings

Settings

Output

Waiting for input

Complete text result

How to use

Set actual foreground, background, and opacity to assess text contrast in each light/dark theme.

Read normal- and large-text criteria separately. A ratio does not certify overall accessibility; images and gradients need checks at the relevant locations.

Examples

#000000
---
#FFFFFF

Principles and limits

Each input is limited to 1,048,576 bytes, output to 33,554,432 bytes, and processing to 5,000 ms. Input is never silently truncated.

Guides

Related tools

Web, UI, and CSS

Color converter

Color converter lets you convert HEX, RGB, HSL, and alpha values with a color preview in your browser.

Web, UI, and CSS

CSS unit converter

CSS unit converter lets you convert px, rem, em, vw, and vh with explicit font and viewport assumptions in your browser.