Color Converter & Contrast Checker
Type or pick a colour and see it in every common format: HEX, RGB, HSL, HSV, HWB, CMYK and the modern OKLCH. Check whether text in that colour is readable on a background with the WCAG contrast ratio, and get a ladder of lighter and darker versions. Everything runs in your browser.
| HEX | #3B82F6 | |
|---|---|---|
| RGB | rgb(59 130 246) | |
| RGB (comma form) | rgb(59, 130, 246) | |
| HSL | hsl(217.2 91.2% 59.8%) | |
| HSV / HSB | hsv(217.2, 76%, 96.5%) | |
| HWB | hwb(217.2 23.1% 3.5%) | |
| CMYK | cmyk(76%, 47.2%, 0%, 3.5%) | |
| OKLCH | oklch(0.6231 0.188 259.81) |
Text contrast (WCAG)
Sample heading text
The quick brown fox jumps over the lazy dog.
3.67 : 1
AA needs 4.5:1 for normal text and 3:1 for large text (18pt, or 14pt bold). AAA needs 7:1 and 4.5:1.
Tints and shades
Tints (towards white)
Shades (towards black)
How to use it
- Type a colour in any format (for example #3b82f6, rgb(59 130 246), hsl(217 91% 60%), oklch(0.62 0.19 260) or a name like tomato), or use the colour picker.
- Copy the value you need from the list of converted formats.
- Under Text contrast, enter a background colour to see the contrast ratio and whether it passes the WCAG AA and AAA levels.
- Click any tint or shade to use it as your colour.
Frequently asked questions
Which colour formats can I enter?
HEX (3, 4, 6 or 8 digits, with or without #), rgb() and rgba(), hsl() and hsla(), hwb(), hsv(), cmyk(), oklch(), oklab() and the 148 CSS colour names. The old comma form and the newer space form with a slash for opacity both work.
What is OKLCH, and why use it?
OKLCH describes a colour by its lightness, chroma (how vivid it is) and hue, in a way that matches how people see colour. Colours with the same lightness number look equally bright, which makes it good for building colour scales and themes. It is supported in current browsers through the CSS oklch() function.
What do the contrast levels mean?
WCAG, the web accessibility standard, asks for a contrast ratio of at least 4.5:1 for normal text and 3:1 for large text at level AA. Level AAA asks for 7:1 and 4.5:1. Higher ratios make text easier to read, especially for people with low vision.
Why does CMYK look different when printed?
CMYK here is a simple mathematical conversion from screen colour. Printers use their own colour profiles and inks, so a printed colour can differ. Ask your printer for a proof if an exact colour matters.
What happens to colours outside the screen’s range?
Some OKLCH colours are more vivid than a standard sRGB screen can show. The tool uses the nearest displayable colour and tells you.
Related tools
These tools run entirely in your browser and are provided free, without warranty. Check important results before using them in production.