Turn HEX Codes Into HSL Values
Paste in a HEX code and find out its Hue, Saturation and Lightness, with each step of the working displayed so you can see exactly how the numbers were reached.
Enter a HEX Colour
HSL Result
hsl(138, 25%, 39%)
HEX: #4A7C59 RGB: rgb(74, 124, 89)
Calculation Stages
Stage 1 — HEX to RGB: #4A7C59 = rgb(74, 124, 89)
Stage 2 — RGB to HSL: rgb(74, 124, 89) = hsl(138, 25%, 39%)
Using the Converter
Type a HEX code, or tap Random Colour for a surprise. The converter then shows two stages on screen: your code is changed into RGB, and that RGB result is then expressed as Hue, Saturation and Lightness.
HSL in Plain Terms
Think of HSL as three dials. Hue picks the spot on the colour wheel, measured from 0 to 360 degrees. Saturation, from 0 to 100%, sets whether the colour is bold or dusty. Lightness, also 0 to 100%, moves it towards white or towards black. Because the colour family is kept apart from its strength and brightness, plenty of painters find this easier to reason about than a string of RGB numbers or a HEX code.
What HSL Helps You Do
Once a colour is in HSL, building variations by hand becomes simple. Hold the hue steady and nudge the lightness to get a tint or a shade, or spin the hue around the wheel to land on complementary and analogous partners. I often do this when planning a geometric tile design: one mosque-tile blue, then several lighter and darker steps of the same hue for the pattern. HSL can also be typed straight into lots of design apps and CSS.
Examples
HSL Questions
What does HSL mean?
The letters stand for Hue, Saturation and Lightness. Hue is an angle on the colour wheel from 0 to 360 degrees, Saturation describes how intense or subdued the colour looks, and Lightness says how close it is to white or black.
How is the conversion carried out?
Your HEX code is first broken into RGB numbers. A standard RGB-to-HSL formula is then applied to calculate the hue, saturation and lightness.
What makes HSL more useful than HEX or RGB?
It keeps the colour family apart from its intensity and brightness, so adjusting a colour into tints, shades or matching harmonies by hand feels far more natural.
Will CSS accept HSL?
It will. Modern browsers understand HSL written straight into a stylesheet, such as hsl(138, 25%, 39%).
How accurate is the result?
Going from HEX to HSL is an exact mathematical process. Apart from the usual rounding used to display the numbers, nothing is estimated or lost.
How do I copy the result?
Press Copy HSL to place it on your clipboard. Copy HEX and Copy RGB are there too if you need those formats.
Are my colours stored anywhere?
They are not. The maths runs inside your own browser, and nothing is kept or passed to a server.
Does the converter cost anything?
No. You can use the HEX to HSL Colour Converter as often as you like without paying, registering or installing anything.
Keep Exploring Colour
HEX to RGB
See the Red, Green and Blue numbers hidden in a HEX code.
HEX to CMYK Colour Converter
Estimate the print ink percentages for a HEX colour.
Colour Picker
Select a shade visually and view its HEX, RGB, HSL and rough CMYK readings.
Tints & Shades Generator
Build a ladder of lighter and darker versions of one colour.
Put Hue and Lightness Into Practice
See how colour theory plays out with real paint using a Creative Flair by Sana painting kit, complete with a harmonious set of colours and clear instructions designed for first-time painters.
Discover Painting KitsAll colour readings here are digital and meant to support planning and learning. Your screen, printer, choice of paint brand, pigments, paper and lighting may all alter how a colour looks, so try out any key colour before it goes into a finished artwork or a print.
