Colour converter
Type or pick a colour to get it in HEX, RGB, HSL, HSB and CMYK, and see if white or black text on it passes the WCAG contrast rules.
FreeNo sign-upRuns on your device
How to use it
- Type a colour in any format, like #1C43F5 or rgb(28, 67, 245), or use the colour picker.
- Copy the format you need from the table.
- Check the contrast results to see if white or black text is readable on it.
The formats
HEX and RGB describe the same thing: how much red, green and blue light to mix, from 0 to 255 each. HEX writes those three numbers in base 16, so #1C43F5 is red 28, green 67 and blue 245.
HSL and HSB (also called HSV) describe a colour by hue, a position on the colour wheel from 0 to 360, then saturation and either lightness or brightness. They are easier for people to adjust: to make a colour lighter, raise the L in HSL. Design tools like Figma show HSB, and CSS supports HSL.
You can type any of these formats into the box, with or without the rgb() or hsl() wrapper, and short HEX codes like #FFF work too. The picker shows the same colour, so you can nudge it by eye and copy the new values.
Why CMYK is approximate
CMYK is the cyan, magenta, yellow and black ink used in print. The conversion here is the standard formula, but real printed colour depends on the paper, the inks and the printer's colour profile. Bright screen colours, especially vivid blues and greens, often can't be printed exactly. Use these CMYK numbers as a starting point and ask your printer for a proof.
Contrast and WCAG
The contrast ratio compares how light two colours are, from 1:1 (the same) to 21:1 (black on white). The Web Content Accessibility Guidelines (WCAG 2.2) ask for at least 4.5:1 for normal text and 3:1 for large text at level AA. Large means about 24 px, or 18.7 px in bold. Level AAA asks for 7:1 and 4.5:1. The tool tests your colour with both white and black text and tells you which reads better.
Privacy
All the maths runs in your browser. Nothing is sent or saved.




