Colour Tools

Convert HEX, RGB, HSL and CMYK colours and check contrast.

Tools in this category

About our Colour Tools

Designers, developers and marketers work with the same colours in different notations: HEX in CSS, RGB in graphics programs, HSL for adjusting shades and CMYK for print. Converting by hand is slow and error-prone.

The Colour Converter translates any colour between HEX, RGB, HSL and CMYK at once. You can type a value or use the colour picker, copy each format with one click and check the WCAG contrast ratio against white and black text to see whether text on that colour is readable.

The tool runs in your browser and works on any device. More colour tools, such as palette generators, are planned for this category.

Practical tips

  • For body text, aim for a contrast ratio of at least 4.5:1 (WCAG AA); large headings need at least 3:1.
  • Use HSL to create lighter or darker shades of a brand colour by changing only the lightness value.
  • CMYK values from a converter are an approximation – ask your print shop for their colour profile for critical jobs.
  • Write HEX colours in lowercase and with all six digits for consistent code.

Frequently asked questions

What is the difference between RGB and HEX?

They describe the same colour. HEX is the hexadecimal notation of the three RGB values, so #1d4ed8 equals rgb(29, 78, 216).

What does the contrast ratio mean?

It compares the brightness of text and background from 1:1 (no contrast) to 21:1 (black on white). WCAG requires at least 4.5:1 for normal text.

Why do printed colours look different?

Screens mix light (RGB), printers mix ink (CMYK). Some bright screen colours cannot be printed exactly.

Can I copy the values directly into CSS?

Yes. HEX, rgb() and hsl() are shown in valid CSS syntax, so you can paste them straight into a stylesheet.

Guides: Colour Tools

More categories