HEX to HSL Converter

Convert a HEX color into hue, saturation, and lightness.

Try an example

Enter a three- or six-digit HEX color.

#2563eb

Expected output

hsl(221.21212 83.19328% 53.33333%)

Common questions

Why does a gray color show hue zero?
Achromatic colors have no meaningful hue. The tool uses zero as a convention when saturation is zero.
Can I paste the result into CSS?
Yes. The output uses the hsl() syntax with saturation and lightness expressed as percentages.

The tool processes your input in this browser. It does not upload the input itself.