Every CSS color keyword in one place
CSS lets you write colors as keywords like tomato, steelblue or
rebeccapurple instead of hex codes. This reference lists all of the CSS Color
Module Level 4 named colors with a live swatch, the canonical hex value, and the
RGB and HSL equivalents computed from it. Search by name or by hex to find the
exact keyword you want.
How it works
Each named color has a fixed sRGB hex value defined by the spec. The tool parses
that hex into red, green and blue bytes (parseInt(slice, 16)), then converts to
HSL with the standard algorithm: it finds the max and min channels to derive
lightness, computes saturation from their spread, and computes hue from which
channel is dominant. All three forms — hex, rgb() and hsl() — describe the
identical color, so you can copy whichever your stylesheet uses.
Tips and notes
- Named colors resolve to exact, standardised hex values, so
redis always#FF0000in every browser. - Several names are aliases:
grayandgrey,aquaandcyan,fuchsiaandmagentaeach share a hex value. - For brand-critical colors, copy the hex and store it in a CSS custom property rather than relying on a keyword.
- HSL is handy when you want to tweak a shade: adjust the lightness percentage to lighten or darken while keeping the same hue.