Light grey text on a white background might look clean and modern on your own screen, but for a lot of readers it is simply hard to read. The same goes for white lettering on a pale brand colour, or a caption sitting on a soft pastel panel. This contrast checker takes the guesswork out of those choices: enter a text colour and a background colour, and it works out the contrast ratio between them and tells you plainly whether that pairing passes the WCAG AA and AAA levels for normal and large text.
It is built for designers choosing palette colours, creators adding text to posts, covers and thumbnails, and anyone publishing words on a coloured background who wants to know the text is genuinely readable before it goes out. Everything happens in your browser on this page. There is no account to create, nothing to install, and the colours you enter are not sent anywhere or stored. Type a hex code or pick a colour visually, watch the ratio and the pass or fail lines update as you go, and adjust until the pairing works.
Quick Answer: This contrast checker compares a text colour with a background colour and gives you the WCAG contrast ratio between them. It shows whether the pair passes AA and AAA for normal and large text, updates live as you type or pick, and includes a preview sentence in your chosen colours so you can see the pairing as readers will.
Type a hex code such as #5B3FD1, with or without the # sign, or use the picker to choose a colour visually. The hex box and the picker stay in step with each other, and the result updates as you change either one.
Large text means roughly 18pt text, or 14pt text in bold. Headings and big cover titles usually count as large text; body copy, captions and small print count as normal text.
Table of Contents
- How to Use the Contrast Checker
- Worked Example
- Key Features
- Best Practices and Tips
- Common Mistakes to Avoid
- When This Tool Helps — and When It Doesn’t
- Frequently Asked Questions
- Related Tools
How to Use the Contrast Checker
- In the Text colour box, type the hex code of the colour your words will be written in, such as the grey or brand colour from your design. You can include the # sign or leave it out.
- If you would rather choose by eye, use the Text colour picker below it and click or tap the shade you want. The hex box updates to match, so you always know the exact code you picked.
- In the Background colour box, type the hex code of the colour that will sit behind the text, or choose it with the Background colour picker in the same way.
- Read the result as it updates. The large number is the contrast ratio between the two colours, and the four lines under it show Pass or Fail for AA and AAA, for normal text and for large text.
- Look at the preview sentence under the result. It is shown in your exact text colour on your exact background colour, so you can judge the pairing with your own eyes as well as by the numbers.
- If the pairing fails the level you need, darken the text colour or lighten the background a step at a time and watch the ratio climb. Small changes are usually enough to turn a near miss into a pass.
- Click Swap colours if you want to test the same two colours the other way round — for example, white text on a brand-coloured button instead of brand-coloured text on white.
Worked Example
Grey text on white is one of the most common pairings on the web, and it is also one of the easiest to get wrong, because greys that look clearly different on a designer’s bright monitor can wash out badly on a phone screen in daylight. Take the mid grey #767676 on a plain white background, #FFFFFF. Enter #767676 in the Text colour box and #FFFFFF in the Background colour box and the checker gives a contrast ratio of 4.54 : 1.
Read the four lines against that ratio. AA for normal text needs 4.5, so 4.54 passes — but only just. AA for large text needs 3.0, so it passes comfortably. AAA for large text needs 4.5, so that passes too. AAA for normal text needs 7.0, and 4.54 falls well short of that, so the strictest line fails. In plain terms, this grey is fine for ordinary body text at the standard AA level and fine for headings at either level, but if you want the stricter AAA standard for body text you would need a noticeably darker grey.
That is exactly the kind of answer the checker is for. Without it, #767676 on white is a judgement call based on how the pairing looks on your screen, in your lighting, with your eyesight. With it, you know the pairing clears AA by a small margin and misses AAA by a wide one, so you can decide deliberately: keep the grey for large headings where it passes everything, and pick something darker for the small print where it only just scrapes through.
Key Features
- Two ways to enter every colour: type an exact hex code when you have one, or use the visual picker when you are still exploring. The hex box and the picker stay in sync both ways, so the code on screen always matches the colour you see.
- The WCAG 2.1 contrast ratio worked out properly, from the relative luminance of each colour, and shown to two decimal places — not a rough brightness guess.
- All four pass levels on one screen: AA and AAA, each for normal text and for large text, with the ratio each level needs printed next to it so you never have to look the thresholds up.
- Live results with no Calculate button to press. The ratio, the four lines and the preview all update the moment you type a character or move the picker.
- A preview sentence rendered in your actual pairing, so you can sanity-check the numbers against how the text really looks at a realistic size.
- A one-click Swap colours button for testing a pairing in reverse, which is the quickest way to check buttons, badges and highlighted text. Everything runs in your browser on this page, so the colours you test stay on your device.
Best Practices and Tips
- Aim for AA as your everyday minimum: 4.5 for normal text and 3.0 for large text. It is the level most accessibility guidance is written around, and meeting it makes text easier for almost everyone, not just people with a diagnosed vision condition.
- Check the smallest text in your design, not the biggest. A pairing that passes easily at headline size can fail at caption or footnote size, and small text is where readers struggle first.
- When a pairing just misses, adjust one colour at a time in small steps. Darkening the text slightly usually moves the ratio more than lightening the background, and changing one colour keeps the rest of your palette intact.
- Test the pairings your design actually uses, including hover states, button text, link colours and text sitting on tinted panels. The main body pairing passing does not mean the pale footer text or the coloured button label passes too.
- Keep a note of the hex codes and ratios for the pairings you settle on. When you reuse your palette across posts, covers and pages, a short list of pairings you have already checked saves you testing the same combinations again.
Common Mistakes to Avoid
- Judging contrast by eye alone. A pairing can look perfectly clear on a bright, high-quality monitor and still fail badly on a dim phone screen or for a reader with low vision. The ratio is the same on every screen; your impression of it is not.
- Only checking large text. A brand colour that passes at 3.0 for a headline does not pass for body copy, which needs 4.5 at AA. Match the line you read to the size the text will actually appear at.
- Treating a bare pass as a target. A ratio of 4.51 passes AA for normal text, but it leaves no room for the slight differences between screens and rendering. If you can get comfortably past the threshold without spoiling the design, do.
- Forgetting that coloured text on a coloured background is the hardest case. Two mid-tone brand colours together often produce a surprisingly low ratio even when each colour looks strong on its own against white or black.
- Checking the default state and nothing else. Links, visited states, disabled buttons and placeholder text inside form fields are all text too, and they are often the palest elements on the page.
When This Tool Helps — and When It Doesn’t
This tool helps whenever you are putting text on a solid colour and want to know, rather than guess, whether people will be able to read it: choosing body text and background colours for a page, setting the label colour on a button, picking caption colours for a post or cover, or checking that a client’s brand palette can be used for text at all. It is also useful in reverse — if a design is already live and readers say the text feels faint, entering the two colours tells you straight away whether the pairing is genuinely below the standard or whether something else is going on.
It has clear limits. It checks one pair of solid colours at a time, so it cannot judge text placed over a photograph, a gradient or a patterned background, where the contrast changes from letter to letter; for those, the honest approach is to test against the lightest and darkest parts of the background behind the text and treat anything in between with caution. It also reports the WCAG ratios and thresholds as a guideline for readable design — WCAG is a widely used standard, but this checker is not legal advice, and whether a particular law or contract requires a particular level for your project is a question for the rules that apply to you, not for a colour tool.
Frequently Asked Questions
What is a contrast ratio, and what do the numbers mean?
The contrast ratio compares how light the lighter of your two colours is with how dark the darker one is, using the WCAG relative luminance formula. Identical colours give 1 : 1, which is completely unreadable, and black on white gives the maximum of 21 : 1. The order you enter the colours does not matter — text on background and background on text give the same ratio — which is why the Swap colours button changes the preview but never changes the number.
Which level should I aim for, AA or AAA?
AA is the level most people work to: 4.5 for normal text and 3.0 for large text. AAA is stricter — 7.0 for normal text and 4.5 for large text — and it is a good target where you can reach it without wrecking a design, especially for long articles or text aimed at older readers. Bear in mind that some pairings simply cannot reach AAA; very few colour combinations get near it while still looking like the colours you started with. Passing AA everywhere and AAA where it is practical is a sensible, honest goal.
Are the colours I enter sent anywhere or saved?
No. The checker runs entirely in your browser on this page. The hex codes you type and the colours you pick are used only to work out the ratio and draw the preview you see, and they are not sent to a server, stored or logged. If you close or refresh the page, the entries reset, so note down any hex codes and ratios you want to keep for your palette.
Related Tools
- Color Converter — Convert a colour between hex, RGB and HSL so you can move codes between design tools.
- Instagram Size Maker — Resize an image to the exact pixel size for a post, story or profile picture.
- Reel Cover Maker — Build a reel cover at the right size, with room for a title people can actually read.