What are HSL colors? Understanding Hue, Saturation, and Lightness

November 14, 2025 • 4 min read
HSL is a way of writing screen colors as hue (which color), saturation (how intense), and lightness (how light or dark), for example hsl(213, 100%, 57%). It describes the same colors as RGB, but in terms that are easier to adjust by hand.


What Does HSL Stand For?

HSL stands for Hue, Saturation, Lightness. It is used in CSS, design tools, and color pickers to describe colors in a form that is often more intuitive than raw RGB values.

In CSS, HSL colors are written as:

hsl(H, S%, L%)
  • H (hue) — an angle in degrees from 0 to 360
  • S (saturation) — a percentage from 0% to 100%
  • L (lightness) — a percentage from 0% to 100%

Example:

hsl(213, 100%, 57%)

This is a bright azure blue (#2387FF): hue in the blue region of the wheel, full saturation, and slightly above-middle lightness.


Hue: Position on the Color Wheel

Hue defines the basic color family and is an angle on a 360° color wheel.

  • 0° → red
  • 60° → yellow
  • 120° → green
  • 180° → cyan
  • 240° → blue
  • 300° → magenta
  • 360° → wraps back to red

Angles in between land in intermediate families: 30° is orange, 90° is yellow-green (chartreuse), and 210° is azure, between cyan and blue. The primary, secondary, and tertiary colors guide maps all twelve 30° steps.


Saturation: Color Intensity

Saturation controls how vivid or muted the color appears. At high saturation the color looks pure and strong; at low saturation it moves toward gray.

  • 100% — fully saturated, pure color
  • 0% — completely desaturated (a gray of some lightness)

With a fixed hue of 213° and lightness of 50%:

hsl(213, 100%, 50%) → vivid blue      #0073FF
hsl(213, 50%, 50%)  → muted blue      #4079BF
hsl(213, 0%, 50%)   → neutral gray    #808080

Reducing saturation is a common way to create subtle, dusty, or muted palettes while keeping the same hue.


Lightness: Bright vs Dark

Lightness controls how light or dark the color appears.

  • 0% lightness — black (regardless of hue or saturation)
  • 50% lightness — the most intense version of the hue
  • 100% lightness — white

With hue and saturation fixed at 213° and 100%:

hsl(213, 100%, 20%) → dark navy        #002E66
hsl(213, 100%, 50%) → vivid blue       #0073FF
hsl(213, 100%, 85%) → pale sky blue    #B2D5FF

Raising lightness mixes the color toward white (a tint); lowering it mixes toward black (a shade). See tints, shades, and tones.


Reading an HSL Color

Consider this example:

hsl(120, 60%, 50%)
  • Hue 120° → green region of the color wheel
  • Saturation 60% → fairly vivid, but not fully saturated
  • Lightness 50% → midpoint between black and white

The result is a medium, moderately saturated green (#33CC33). Raising lightness to 70–80% gives lighter greens for backgrounds; lowering it to 30–40% gives darker versions for text or accents.


HSL vs RGB vs HEX

HSL, RGB, and HEX describe the same colors in different notation:

#2387FF
rgb(35, 135, 255)
hsl(213, 100%, 57%)
Format What It Describes Strengths
RGB Red, green, and blue channel intensities Maps closely to display hardware
HEX RGB channels written in base-16 Compact, widely used in CSS and style guides
HSL Hue angle, saturation, and lightness Convenient for systematic tints, shades, and muted variants

A common pattern is to store and share colors as HEX, and adjust or generate related colors in HSL.


Why Designers Use HSL

Each HSL component maps directly to a familiar design decision:

  • Keep the hue, raise lightness for backgrounds, lower it for text or borders
  • Lower saturation to create muted or neutral variants of a brand color
  • Shift hue slightly to explore related colors while keeping saturation and lightness

That makes palettes easier to build than adjusting three RGB channels by hand. It does not guarantee consistent contrast, because HSL lightness is not perceived brightness (see the first pitfall below).


What Is HSLA?

HSLA adds an alpha channel for opacity, the same way RGBA extends RGB:

hsla(H, S%, L%, A)

The alpha value A ranges from 0 (transparent) to 1 (opaque).

hsla(213, 100%, 57%, 1)   → opaque blue
hsla(213, 100%, 57%, 0.5) → 50% transparent blue
hsla(0, 0%, 0%, 0.3)      → semi-transparent black overlay

Modern CSS also accepts the space-separated form hsl(213 100% 57% / 0.5) and treats hsla() as an alias of hsl().


Common Pitfalls

  • Treating lightness as perceived brightness. hsl(60, 100%, 50%) (yellow) and hsl(240, 100%, 50%) (blue) share the same L, but yellow has a relative luminance of about 0.93 and blue about 0.07. White text passes contrast on the blue and fails badly on the yellow. See color value.
  • Expecting the hue to survive at 0% saturation. hsl(H, 0%, L%) is always a gray, whatever H is.
  • Using 100% saturation for UI colors. Fully saturated values such as hsl(120, 100%, 50%) (#00FF00) look harsh on screen and fall outside the CMYK print gamut.
  • Rounding errors in round-trips. Converting HEX → HSL with whole-number percentages and back can shift a channel by one or two values, so store the HEX as the source of truth.

Where HSL and HSLA Are Used

  • CSS for web interfaces and component libraries
  • Design tools and color picker panels
  • Design systems and token-based color scales
  • Theming systems, including dark mode and high-contrast modes

Using HSL in Practice

A typical workflow starts with one or two base hues and derives supporting colors by adjusting saturation and lightness:

  • Set a base brand color, such as hsl(213, 100%, 57%)
  • Raise lightness to 85–95% for backgrounds or hover states
  • Lower lightness to 25–35% for emphasis or outlines
  • Drop saturation to 5–15% to build neutrals from the same hue

The swatch.ing color converter shows any color in HSL next to HEX and RGB, with nine tints and shades.

With practice, HSL values become predictable: you can look at hsl(210, 20%, 30%) and know it will be a dark, muted blue suitable for a background or subdued text.

Keep learning

More on color formats

All guides