Color Converter (HEX, RGB, HSL)
Convert a colour between HEX, RGB, HSL and other formats.
The same colour, written many ways
A colour can be written as a hex code, as RGB values, as HSL, and more — the same colour, different notation for different contexts. This converts between them, so a hex code from a design tool becomes the RGB or HSL your code needs, or vice versa, without you doing the arithmetic.
Enter a colour in any format and see it in the others.
Why HSL is worth knowing
Hex and RGB describe a colour by how much red, green and blue it mixes, which is precise but unintuitive to adjust — it is hard to make a colour a little lighter by tweaking three numbers. HSL describes it by hue, saturation and lightness instead, which maps to how people actually think about colour: pick the hue, then adjust how vivid and how light it is. That makes HSL far friendlier for creating variations of a colour, which is why converting into it is so useful when building a palette.
Frequently asked questions
What formats does it convert between?
HEX, RGB and HSL, among others — the same colour expressed in each notation.
Why use HSL over RGB?
HSL describes hue, saturation and lightness, which matches how people think about colour and makes adjusting shades far easier than tweaking RGB.
Is anything uploaded?
No. The conversion happens in your browser.