Back

Contrast checker

Color and palettes

Loading

Loading tool

Preparing the tool. The remaining time is not yet known.

All processing for this tool happens in your browser. Your input is not sent to a server.

About this tool

Calculate the relative-luminance contrast ratio of two opaque HEX colors.

Common uses

  • Calculate the relative-luminance contrast ratio of two opaque HEX colors.
  • Enter foreground and background colors using three- or six-digit HEX.

How to use it

  1. 1.Enter foreground and background colors using three- or six-digit HEX.
  2. 2.Read the ratio and normal/large-text AA and AAA indicators, then copy the report.

Worked example

Input and result

#000 / #fff
21:1; normal-text AAA: pass

Opaque black and white give the maximum sRGB contrast ratio.

Limits and notes

  • Uses thresholds 4.5/7 for normal text and 3/4.5 for large text. It does not determine whether your actual font qualifies as large or evaluate transparency and images.

Frequently asked questions

What does this tool do?

Calculate the relative-luminance contrast ratio of two opaque HEX colors.

What should I check before using the result?

Uses thresholds 4.5/7 for normal text and 3/4.5 for large text. It does not determine whether your actual font qualifies as large or evaluate transparency and images.

Related tools