HEX, RGB and HSL Colors Explained (With a Free Converter)

Designers and developers describe colors in different formats. The free color converter changes a color between HEX, RGB and HSL.

The three formats

  • HEX: a code such as #1d4ed8, common in web design.
  • RGB: three numbers from 0 to 255 for red, green and blue.
  • HSL: hue (0 to 360), saturation and lightness as percentages.

How to use the converter

  1. Open the Color Converter.
  2. Pick a color with the color picker, or type a value into any box.
  3. The other formats update automatically.
  4. Copy the format you need for your CSS or design tool.

Why HSL is handy

HSL makes it easy to create lighter or darker versions of a color: keep the hue and change the lightness. It is also easier to reason about than three RGB numbers.

If you type an invalid value, the tool tells you what format it expects. Try the Color Converter now, and see our other developer tools such as the JSON Formatter.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top