Nearest CSS Colour Name Finder

Find the closest CSS named colour to any hex or RGB value.

Free nearest CSS colour name finder. Enter any hex or RGB colour and get the closest of the 148 CSS named colours by perceptual distance, an exact-match flag, and the next four closest alternatives. Runs entirely in your browser. It runs free in your browser on Gera Tools, with nothing uploaded.

Last updated Source: Gera Tools

Which colour names does this use?

It uses the 148 named colours defined in the CSS Color Module Level 4 specification — the standard keyword set every browser recognises, such as tomato, steelblue and rebeccapurple. It is the real W3C list, not an invented palette.

CSS ships with 148 named colours — from tomato to rebeccapurple — but your design tool gives you a hex value. This finder maps any hex or RGB colour to the closest CSS keyword, so you can use a readable name or just find out what a colour is called.

How “closest” is measured

Rather than plain RGB distance, the tool uses the redmean formula, a lightweight approximation of human colour perception:

rmean = (r1 + r2) / 2
Δ = √( (2 + rmean/256)·Δr²  +  4·Δg²  +  (2 + (255−rmean)/256)·Δb² )

The named colour with the smallest Δ wins. If Δ is essentially zero, your colour exactly matches a keyword and the tool says so.

The colour list is the real standard

The 148 entries are exactly the keywords from the CSS Color Module Level 4 specification that every browser recognises — the same set you can use directly in CSS like color: steelblue. Nothing is fabricated; it is the W3C list.

Uses

  • Turn an exported hex into a readable keyword for quick prototyping.
  • Answer “what colour is #6d8bff?” (it is closest to cornflowerblue).
  • Sanity-check a brand colour against the nearest standard names.

Everything runs locally in your browser, including the four runner-up matches so you can pick the best fit.