Colour Love

Why there are 16,777,216 colours

The number on our homepage is a precise maths result, not a marketing round. Here is where 16,777,216 comes from, why the web settled on it, and what your eye can actually perceive.

On the Colour Love homepage we claim there are 16,777,216 colours in existence. That number is not picked to sound impressive, it is the exact, non-rounded total produced by a specific technical decision made by the people who built the modern web in the 1990s. It also happens to be a decent approximation of the number of colours a screen can display and, by coincidence, more than a human eye can reliably distinguish.

Three claims, one oddly round binary number. Here is each of them.

Where the number comes from

The modern web stores colour using what is called 24-bit True Color, sometimes written as 24bpp (bits per pixel). Every colour on your screen is a combination of three channels, red, green, blue, and each channel is assigned exactly 8 bits of information.

  • 8 bits per channel
  • 3 channels
  • Total: 24 bits per pixel

A bit is a yes-or-no, 0 or 1. Eight bits strung together can count from 00000000 to 11111111, which in decimal is 0 to 255. That gives each of red, green, and blue exactly 256 possible values.

Multiply it out: 256 × 256 × 256 = 16,777,216.

It is not a marketing number. It is two to the power of 24. Or, if you prefer, it is every possible combination of three bytes.

Colours per bit depth (log scale) More bits = more possible colours, with diminishing perceptual returns. 8-bit (web) 10-bit (HDR) 12-bit (cinema) Human eye (est.) 16.7M 1.07B 68.7B ~1–10M Bar widths are logarithmic. Linear bars would make 8-bit invisible next to 12-bit.
8-bit gives more codes than the eye needs, but gradients still band. 10-bit erases banding.

Why 8 bits per channel

The decision to allocate 8 bits per channel was made in the late 1980s and early 1990s, mostly by graphics hardware manufacturers and the VESA standards body, and then picked up by operating systems (Microsoft, Apple) and, eventually, the web.

Several factors converged:

  • A byte (8 bits) is a natural unit for computer memory. Three bytes make a convenient 24-bit pixel, which is straightforward for hardware to handle.
  • 256 values per channel was seen, at the time, as the point at which colour banding, visible stripes in gradients, becomes almost imperceptible to untrained eyes.
  • Memory was still expensive. Going to 10 or 12 bits per channel would have meant 30 or 36 bits per pixel, awkward to pack and more than most consumer graphics cards of the era could cheaply support.

So 24-bit colour became the default, and when the web arrived, CSS and HTML picked it up without debate. Hex notation, #RRGGBB, is a direct reflection of this choice, two hex digits per channel is exactly the range of one byte.

What your eye can actually see

The interesting next question is: can a human eye tell 16,777,216 colours apart?

The answer depends on what you mean by “tell apart.” In ideal laboratory conditions, looking at two colours side by side in neutral lighting, a trained observer with good vision can distinguish somewhere between one and ten million distinct colours. The exact number is disputed in the colour-science literature, and individual variation is enormous. Women tend to distinguish slightly more colours than men, for reasons tied to X-chromosome-linked cone-cell genetics. Certain populations have a higher prevalence of colour-blindness, which reduces the count significantly. Age, lighting, and fatigue all degrade the count further.

In practice, in real-world conditions, looking at two similar colours on different parts of a screen, most people can reliably distinguish far fewer than a million. The design and print industries have known this for decades, which is why small print swatches and on-screen colour pickers do not need infinite precision to be useful.

So 16,777,216 is comfortably in the “more than we need” category. It is a technical ceiling, not a perceptual one.

10-bit and 12-bit colour, the next steps up

Some newer displays, particularly high-end professional monitors and modern televisions marketed as HDR, use 10 bits per channel instead of 8. The maths:

  • 10 bits per channel
  • 3 channels
  • 2^30 = 1,073,741,824 colours

Or, one billion and change. 12-bit colour exists too, mainly in cinema mastering workflows, 2^36 = 68,719,476,736 colours, roughly 68 billion.

You will not notice these bigger numbers the way you notice a bigger screen. Where they matter is in gradients. 8-bit colour produces visible banding in smooth gradients under certain lighting conditions, especially in dark scenes or sky-like images. 10-bit smooths this out to the point where banding is essentially invisible, even to trained eyes.

The web is slowly catching up. CSS Colors Level 4 introduced color() function notation that can specify colours in wider gamuts than 8-bit sRGB. Browsers, operating systems, and display manufacturers are in various stages of support. But for most day-to-day work, and for everything on Colour Love, 8-bit 24-bit True Color is still the standard, and 16,777,216 is the number to remember.

The sRGB qualifier

There is a subtlety. 16,777,216 is the number of codes available in 24-bit colour. It is not necessarily the number of distinct colours those codes can represent, because the colours they represent depend on which colour space you are interpreting the codes in.

The default colour space on the web is called sRGB, specified in 1996 by HP and Microsoft and later ratified as IEC 61966-2-1. sRGB defines exactly which physical colours the 24-bit codes correspond to, what does #FF0000 look like, specifically, as a wavelength and intensity of light.

sRGB is a relatively narrow gamut by modern standards. It covers a smaller range of the total visible spectrum than, say, Display P3 (used on modern Apple devices) or Rec. 2020 (used in 4K television). The same 24-bit code, interpreted in a wider gamut, represents a more saturated version of the same colour.

So “16,777,216 colours” is more precisely “16,777,216 sRGB codes,” and the actual range of perceivable colours covered depends on your screen’s gamut. Most consumer screens in 2026 are sRGB or close to it. Premium screens extend into Display P3 or DCI-P3. The underlying 24-bit ceiling is the same; the colours it points to are slightly different.

The homepage number, re-examined

When we say “16,777,216 colours exist” on the Colour Love homepage, what we actually mean is: there are exactly that many distinct 24-bit sRGB codes. Each code corresponds to a colour your screen can display. Most of those colours have never been given a name. Some of them have been given seventeen names across competing standards, for reasons we will get into in a separate article on naming.

The number is round in the sense that it is exactly 2 to the power of 24. It is ragged-looking in decimal for the same reason 1,024 (2^10) is ragged-looking. Computers are comfortable with it. Humans are not.

One way to make it feel real: if you named one colour per second, non-stop, without sleeping, it would take you six months and seventeen days to name every colour in the 24-bit sRGB space. Ambitious. Achievable in theory. A small adoption at a time.

Frequently asked questions

Why exactly 16,777,216 colours?
It is 2 to the power of 24, the exact count of unique values you can store in 24 bits. The modern web uses 8 bits per channel across three channels (red, green, blue), giving 256 × 256 × 256 = 16,777,216.
Can the human eye actually see that many colours?
Under ideal conditions a trained observer can distinguish between roughly one and ten million distinct colours. In real-world usage, most people reliably distinguish far fewer. 16,777,216 is a technical ceiling, not a perceptual one.
What is 10-bit or 12-bit colour?
10-bit uses 10 bits per channel, 2^30 ≈ 1.07 billion colours. 12-bit uses 12 bits per channel, 2^36 ≈ 68 billion. These matter mostly for smooth gradients and HDR content, not general web work.
What is sRGB and why does it matter?
sRGB is the default colour space of the web, specified in 1996. It defines which physical wavelengths each 24-bit code corresponds to. Wider gamuts like Display P3 interpret the same codes as more saturated colours.
Is 16,777,216 the same across all screens?
The count of codes is the same, but the exact physical colour each code represents shifts with gamut. A code on a Display P3 screen is more saturated than the same code on an sRGB screen.
Why did the web settle on 8 bits per channel?
Byte alignment (8 bits = 1 byte), early-1990s memory cost, and the perceptual threshold where banding becomes hard to see with the naked eye. 24-bit True Color became the consumer default and the web inherited it.

Defined terms

24-bit True Color
The colour depth standard of the modern web. 8 bits per channel across red, green, blue, 24 bits per pixel, 16,777,216 possible values.
Bit
A single binary digit, 0 or 1. Eight bits combine to form one byte, which can store values 0–255.
Gamut
The range of colours a given medium or colour space can reproduce. Wider gamuts (Display P3, Rec. 2020) cover more of human vision than narrower ones (sRGB).
Banding
Visible stripes in a gradient caused by insufficient colour depth. More bits per channel means smoother gradients and less banding.
CIE 1931
The international mathematical model of human-visible colour, published by the Commission Internationale de l'Éclairage. Every modern colour space is defined relative to it.
HDR
High Dynamic Range. Content that uses wider colour depth (often 10-bit) and higher brightness range than standard displays, producing smoother gradients and more vivid colour.

More articles