Skip to content

CSS color names

All 148 named colors you can use in CSS and HTML, with their hex codes. Choose one for its full set of values, shades and matching colors.

139 colors

Reds

Pinks

Oranges

Browns

Yellows

Greens

Cyans

Blues

Purples

Whites

Grays and black

History

Where the color names come from

HTML 4 defined 16 basic color names, such as red, navy, teal and olive. CSS later added a long list of extended names taken from the X11 window system of Unix workstations, which is why there are colors like papaya whip, peach puff and lemon chiffon. The latest addition is rebecca purple, added in 2014 in memory of Rebecca Meyer, daughter of CSS pioneer Eric Meyer.

Because the lists were merged rather than designed, there are a few surprises: dark gray is lighter than gray, green is darker than lime, and some colors have two names, such as aqua and cyan.

Using color names

A color name works anywhere a color value does: color: tomato;, background: aliceblue; or border-color: teal;. To fine-tune a named color, open it here and copy its HEX, RGB, HSL or OKLCH value instead.

Frequently asked questions

How many named colors does CSS have?

148. Some of them are the same color under two names: gray and grey (and the other gray shades), aqua and cyan, and fuchsia and magenta. That leaves 139 different colors, each with its own page here.

Are CSS color names case-sensitive?

No. Coral, CORAL and coral all work. Lowercase is the usual style, and that is how the names are listed here.

Do all browsers support these color names?

Yes. Every browser in use today supports all 148 names, in CSS as well as in SVG and the canvas API.

Should I use color names or hex codes?

Names are handy for quick prototypes and examples, because they are easy to read. For a real design, hex, RGB or OKLCH values give you exact control over every shade, and the names cover only a small, uneven selection of colors.

Why is dark gray lighter than gray?

Dark gray is #A9A9A9 and gray is #808080. The extended color names came from the X11 window system, where gray was lighter than the gray HTML already had. CSS kept the HTML gray, so the X11 "dark" gray ended up lighter.