How to use it
- Pick a hue on the rainbow bar, then drag in the square to set how strong and how bright the color is.
- Or type a value into any field: HEX, RGB, HSL or CMYK. The others follow as you type.
- Press Copy next to the format you need.
- Check the contrast boxes before using the color for text, and click a tint or shade to try a lighter or darker version.
Which format to use
- HEX (
#1f57c3) is the usual way to write a color in CSS, design tools and brand guides. - RGB gives the red, green and blue amounts from 0 to 255. Use it when you need transparency, as in
rgb(31 87 195 / 50%). - HSL is hue (0–360°), saturation and lightness. It is the easiest to adjust by hand: change only the lightness to get a darker version of the same color.
- CMYK is for print. The numbers here are a simple conversion; a printer working to a specific press profile will give slightly different values.
Contrast and WCAG
The contrast ratio compares the color with white and with black, from 1:1 (no difference) to 21:1 (black on white). The WCAG 2 guidelines ask for at least 4.5:1 for normal text (AA), 7:1 for the stricter AAA level, and 3:1 for large text of about 24 px, or 19 px bold. The ratio is rounded down, so a color that shows 4.50:1 really does pass.
Questions
How do I pick a color from something on my screen?
In Chrome, Edge and Opera on a computer, press Pick from screen and click anywhere, even outside the browser. Other browsers do not offer this yet, so the button is hidden. You can take a screenshot and use the color picker from image instead.
Why does my CMYK value differ from Photoshop?
Photoshop converts through a color profile for a particular paper and press, while this tool uses the plain formula. Use these numbers as a starting point and ask your printer for exact values.
Can I use 3-digit HEX codes?
Yes. Type
#36c and it is read as #3366cc.Is my last color saved?
Yes, in this browser only, so the picker opens on the color you used last. Nothing is sent anywhere.