🌐 English

Home › Guides

Color codes: what's the difference?

The same purple can be written #7c3aed, rgb(124, 58, 237) or hsl(262, 83%, 58%). Each notation has its own use.

Ways to write screen colors

Print color is CMYK

CMYK is the mix of cyan, magenta, yellow and black ink. Screens and print make color differently, so the same numbers don't come out identical (see “Screen vs print color”).

Which should you use?

HEX or RGB are fine for web code; HSL or OKLCH are handier if you tweak colors often. For design-system shade scales, OKLCH gives the most even results.