Short answer: hex, by far; rgb() is second, and hsl() is on many sites but few values
Hex, RGB or HSL: which do websites use?
Hex is the most common color notation on websites today. Of the 996 most-linked home pages that Recolor (recolor.page) measured on October 8, 2026, 99.6% write at least one hex code, and hex is 81% of every color value in their CSS. The findings come from The colors of the web 2026, where rgb() comes second and hsl() accounts for a small share of values.
Last updated
| Notation | Sites that write it | Share of all color values |
|---|---|---|
Hex codes, such as #155dfc | 99.6% | 81% |
rgb() and rgba() | 89% | 15% |
Named colors, such as white | 75% | 1.2% |
hsl() and hsla() | 37% | 1.3% |
Channels for rgb() or hsl() to read | 16% | 0.7% |
oklch() | 5.9% | 0.7% |
How the sites write their colors
The study read 1,181,518 color values in the CSS of the 996 sites, as each page wrote them, following the
process described in the methodology. By sites, hex appears
on 99.6%, rgb() and rgba() on 89%, named colors such as white or black on
75%, and hsl() and hsla() on 37%.
By values, hex makes up 81% of the colors found, while rgb() represents 15%. Named
colors and hsl() each represent about one value in a hundred. In total, 48% of the sites write
nothing but hex codes, named colors and rgb().
Share of sites. A site counts once for every notation it uses.
The numbers
| Notation | Sites using it | Share of sites | Share of all color values |
|---|---|---|---|
| Hex (#rrggbb) | 992 | 99.6% | 81% |
| rgb() and rgba() | 890 | 89% | 15% |
| Named colors | 745 | 75% | 1.2% |
| hsl() and hsla() | 372 | 37% | 1.3% |
| Channels in a variable | 164 | 16% | 0.7% |
| oklch() | 59 | 5.9% | 0.7% |
| oklab() | 23 | 2.3% | under 0.1% |
| lab() | 19 | 1.9% | 0.1% |
| color() | 12 | 1.2% | under 0.1% |
| hwb() | 2 | 0.2% | 0% |
| lch() | 1 | 0.1% | 0% |
Why hsl() is on many sites but few values
A total of 372 sites write at least one hsl() color, but those values are 1.3% of the
total across the study. A site that uses hsl() tends to use it for a few colors, not its whole palette.
Channels, which are variables that hold bare numbers for rgb() or hsl() to read, such as --background: 255, 255, 255, appear on 16% of the sites.
HSL's lightness also misleads. Two colors at the same HSL lightness can differ a lot in how light they look, which makes it harder to make a palette accessible. Designers often look at what OKLCH is to avoid these uneven perceived brightness steps.
Where the newer notations stand
The oklch() notation is on 5.9% of the sites and 0.7% of the values, making it the
CSS Color 4 notation used most. You can see how every newer notation compares on the OKLCH adoption in
2026 page. The color-mix() function is on 22% of the measured
sites.
Which one to write
All three formats describe the same sRGB colors, so the choice depends on how you want to read and change
them. Hex is the shortest format and the default output that most design tools hand out. The oklch()
notation makes even steps of lightness and reaches wider-gamut colors on displays that support them.
Recolor reads every notation when it loads a page, and its exports write hex codes. The CSS named colors each have a reference page with their hex, RGB and HSL values. You can load a site into the Recolor app and press Space to test new combinations live.
Common questions
Is hex the most common color notation on websites?
Yes. 99.6% of the most-linked home pages write at least one hex code, and hex is 81% of their color values.
Is rgb() more common than hsl()?
Yes. rgb() is on 89% of the sites and hsl() on 37%.
Do most sites write their whole palette in hsl()?
No. hsl() values are 1.3% of all the color values the study read.
Are named colors common?
Yes. 75% of the sites write at least one, such as white or black, but they are few of the values.
Does Recolor read hsl() and oklch() colors?
Yes. It reads every CSS color notation when it loads a page.
Can I use the data?
Yes. The dataset is licensed CC BY 4.0; credit Recolor and link the study.
Sources
- Recolor's colors of the web 2026 study recolor.page