W3C Color Names: Complete List of All 148 CSS Named Colors
W3C color names are 148 predefined color keywords, such as red, tomato and rebeccapurple, that you can use instead of hex or RGB codes in HTML and CSS. They are defined in the W3C’s CSS Color Module Level 4, they are case-insensitive, and each one maps to the same exact color in every modern browser.
Below you’ll find the full list with hex and RGB values, the same colors grouped by shade, the 16 original basic colors, and working code examples. Every name and value on this page has been checked against the current W3C specification.
| Quick facts | Value |
| Total named colors | 148 |
| Unique color values | 139 (9 names are duplicates) |
| Basic colors in HTML 4 | 16 |
| Basic colors in CSS 2.1 | 17 (orange was added) |
| Newest addition | rebeccapurple, #663399 (2014) |
| Share of all 16,777,216 sRGB colors | about 0.0008% |
| Case-sensitive? | No |
Key takeaways
- There are 148 W3C color names, but only 139 distinct colors, because of duplicates like gray/grey and aqua/cyan.
- Every name works in every modern browser and renders as one fixed value.
- darkgray (#A9A9A9) is lighter than gray (#808080), a quirk inherited from the X11 color system.
- Named colors are great for prototypes, demos and readable code, but brand colors usually need hex, RGB or HSL.
- transparent and currentColor are color keywords too, but they are not part of the 148.
Full List of W3C Color Names (Hex and RGB)
All 148 names are listed alphabetically. Type any keyword exactly as shown, in any letter case, wherever CSS accepts a color.
Download the full W3C color names list (PDF)
| Color name | Hex code | RGB value |
| aliceblue | #F0F8FF | rgb(240, 248, 255) |
| antiquewhite | #FAEBD7 | rgb(250, 235, 215) |
| aqua | #00FFFF | rgb(0, 255, 255) |
| aquamarine | #7FFFD4 | rgb(127, 255, 212) |
| azure | #F0FFFF | rgb(240, 255, 255) |
| beige | #F5F5DC | rgb(245, 245, 220) |
| bisque | #FFE4C4 | rgb(255, 228, 196) |
| black | #000000 | rgb(0, 0, 0) |
| blanchedalmond | #FFEBCD | rgb(255, 235, 205) |
| blue | #0000FF | rgb(0, 0, 255) |
| blueviolet | #8A2BE2 | rgb(138, 43, 226) |
| brown | #A52A2A | rgb(165, 42, 42) |
| burlywood | #DEB887 | rgb(222, 184, 135) |
| cadetblue | #5F9EA0 | rgb(95, 158, 160) |
| chartreuse | #7FFF00 | rgb(127, 255, 0) |
| chocolate | #D2691E | rgb(210, 105, 30) |
| coral | #FF7F50 | rgb(255, 127, 80) |
| cornflowerblue | #6495ED | rgb(100, 149, 237) |
| cornsilk | #FFF8DC | rgb(255, 248, 220) |
| crimson | #DC143C | rgb(220, 20, 60) |
| cyan | #00FFFF | rgb(0, 255, 255) |
| darkblue | #00008B | rgb(0, 0, 139) |
| darkcyan | #008B8B | rgb(0, 139, 139) |
| darkgoldenrod | #B8860B | rgb(184, 134, 11) |
| darkgray | #A9A9A9 | rgb(169, 169, 169) |
| darkgreen | #006400 | rgb(0, 100, 0) |
| darkgrey | #A9A9A9 | rgb(169, 169, 169) |
| darkkhaki | #BDB76B | rgb(189, 183, 107) |
| darkmagenta | #8B008B | rgb(139, 0, 139) |
| darkolivegreen | #556B2F | rgb(85, 107, 47) |
| darkorange | #FF8C00 | rgb(255, 140, 0) |
| darkorchid | #9932CC | rgb(153, 50, 204) |
| darkred | #8B0000 | rgb(139, 0, 0) |
| darksalmon | #E9967A | rgb(233, 150, 122) |
| darkseagreen | #8FBC8F | rgb(143, 188, 143) |
| darkslateblue | #483D8B | rgb(72, 61, 139) |
| darkslategray | #2F4F4F | rgb(47, 79, 79) |
| darkslategrey | #2F4F4F | rgb(47, 79, 79) |
| darkturquoise | #00CED1 | rgb(0, 206, 209) |
| darkviolet | #9400D3 | rgb(148, 0, 211) |
| deeppink | #FF1493 | rgb(255, 20, 147) |
| deepskyblue | #00BFFF | rgb(0, 191, 255) |
| dimgray | #696969 | rgb(105, 105, 105) |
| dimgrey | #696969 | rgb(105, 105, 105) |
| dodgerblue | #1E90FF | rgb(30, 144, 255) |
| firebrick | #B22222 | rgb(178, 34, 34) |
| floralwhite | #FFFAF0 | rgb(255, 250, 240) |
| forestgreen | #228B22 | rgb(34, 139, 34) |
| fuchsia | #FF00FF | rgb(255, 0, 255) |
| gainsboro | #DCDCDC | rgb(220, 220, 220) |
| ghostwhite | #F8F8FF | rgb(248, 248, 255) |
| gold | #FFD700 | rgb(255, 215, 0) |
| goldenrod | #DAA520 | rgb(218, 165, 32) |
| gray | #808080 | rgb(128, 128, 128) |
| green | #008000 | rgb(0, 128, 0) |
| greenyellow | #ADFF2F | rgb(173, 255, 47) |
| grey | #808080 | rgb(128, 128, 128) |
| honeydew | #F0FFF0 | rgb(240, 255, 240) |
| hotpink | #FF69B4 | rgb(255, 105, 180) |
| indianred | #CD5C5C | rgb(205, 92, 92) |
| indigo | #4B0082 | rgb(75, 0, 130) |
| ivory | #FFFFF0 | rgb(255, 255, 240) |
| khaki | #F0E68C | rgb(240, 230, 140) |
| lavender | #E6E6FA | rgb(230, 230, 250) |
| lavenderblush | #FFF0F5 | rgb(255, 240, 245) |
| lawngreen | #7CFC00 | rgb(124, 252, 0) |
| lemonchiffon | #FFFACD | rgb(255, 250, 205) |
| lightblue | #ADD8E6 | rgb(173, 216, 230) |
| lightcoral | #F08080 | rgb(240, 128, 128) |
| lightcyan | #E0FFFF | rgb(224, 255, 255) |
| lightgoldenrodyellow | #FAFAD2 | rgb(250, 250, 210) |
| lightgray | #D3D3D3 | rgb(211, 211, 211) |
| lightgreen | #90EE90 | rgb(144, 238, 144) |
| lightgrey | #D3D3D3 | rgb(211, 211, 211) |
| lightpink | #FFB6C1 | rgb(255, 182, 193) |
| lightsalmon | #FFA07A | rgb(255, 160, 122) |
| lightseagreen | #20B2AA | rgb(32, 178, 170) |
| lightskyblue | #87CEFA | rgb(135, 206, 250) |
| lightslategray | #778899 | rgb(119, 136, 153) |
| lightslategrey | #778899 | rgb(119, 136, 153) |
| lightsteelblue | #B0C4DE | rgb(176, 196, 222) |
| lightyellow | #FFFFE0 | rgb(255, 255, 224) |
| lime | #00FF00 | rgb(0, 255, 0) |
| limegreen | #32CD32 | rgb(50, 205, 50) |
| linen | #FAF0E6 | rgb(250, 240, 230) |
| magenta | #FF00FF | rgb(255, 0, 255) |
| maroon | #800000 | rgb(128, 0, 0) |
| mediumaquamarine | #66CDAA | rgb(102, 205, 170) |
| mediumblue | #0000CD | rgb(0, 0, 205) |
| mediumorchid | #BA55D3 | rgb(186, 85, 211) |
| mediumpurple | #9370DB | rgb(147, 112, 219) |
| mediumseagreen | #3CB371 | rgb(60, 179, 113) |
| mediumslateblue | #7B68EE | rgb(123, 104, 238) |
| mediumspringgreen | #00FA9A | rgb(0, 250, 154) |
| mediumturquoise | #48D1CC | rgb(72, 209, 204) |
| mediumvioletred | #C71585 | rgb(199, 21, 133) |
| midnightblue | #191970 | rgb(25, 25, 112) |
| mintcream | #F5FFFA | rgb(245, 255, 250) |
| mistyrose | #FFE4E1 | rgb(255, 228, 225) |
| moccasin | #FFE4B5 | rgb(255, 228, 181) |
| navajowhite | #FFDEAD | rgb(255, 222, 173) |
| navy | #000080 | rgb(0, 0, 128) |
| oldlace | #FDF5E6 | rgb(253, 245, 230) |
| olive | #808000 | rgb(128, 128, 0) |
| olivedrab | #6B8E23 | rgb(107, 142, 35) |
| orange | #FFA500 | rgb(255, 165, 0) |
| orangered | #FF4500 | rgb(255, 69, 0) |
| orchid | #DA70D6 | rgb(218, 112, 214) |
| palegoldenrod | #EEE8AA | rgb(238, 232, 170) |
| palegreen | #98FB98 | rgb(152, 251, 152) |
| paleturquoise | #AFEEEE | rgb(175, 238, 238) |
| palevioletred | #DB7093 | rgb(219, 112, 147) |
| papayawhip | #FFEFD5 | rgb(255, 239, 213) |
| peachpuff | #FFDAB9 | rgb(255, 218, 185) |
| peru | #CD853F | rgb(205, 133, 63) |
| pink | #FFC0CB | rgb(255, 192, 203) |
| plum | #DDA0DD | rgb(221, 160, 221) |
| powderblue | #B0E0E6 | rgb(176, 224, 230) |
| purple | #800080 | rgb(128, 0, 128) |
| rebeccapurple | #663399 | rgb(102, 51, 153) |
| red | #FF0000 | rgb(255, 0, 0) |
| rosybrown | #BC8F8F | rgb(188, 143, 143) |
| royalblue | #4169E1 | rgb(65, 105, 225) |
| saddlebrown | #8B4513 | rgb(139, 69, 19) |
| salmon | #FA8072 | rgb(250, 128, 114) |
| sandybrown | #F4A460 | rgb(244, 164, 96) |
| seagreen | #2E8B57 | rgb(46, 139, 87) |
| seashell | #FFF5EE | rgb(255, 245, 238) |
| sienna | #A0522D | rgb(160, 82, 45) |
| silver | #C0C0C0 | rgb(192, 192, 192) |
| skyblue | #87CEEB | rgb(135, 206, 235) |
| slateblue | #6A5ACD | rgb(106, 90, 205) |
| slategray | #708090 | rgb(112, 128, 144) |
| slategrey | #708090 | rgb(112, 128, 144) |
| snow | #FFFAFA | rgb(255, 250, 250) |
| springgreen | #00FF7F | rgb(0, 255, 127) |
| steelblue | #4682B4 | rgb(70, 130, 180) |
| tan | #D2B48C | rgb(210, 180, 140) |
| teal | #008080 | rgb(0, 128, 128) |
| thistle | #D8BFD8 | rgb(216, 191, 216) |
| tomato | #FF6347 | rgb(255, 99, 71) |
| turquoise | #40E0D0 | rgb(64, 224, 208) |
| violet | #EE82EE | rgb(238, 130, 238) |
| wheat | #F5DEB3 | rgb(245, 222, 179) |
| white | #FFFFFF | rgb(255, 255, 255) |
| whitesmoke | #F5F5F5 | rgb(245, 245, 245) |
| yellow | #FFFF00 | rgb(255, 255, 0) |
| yellowgreen | #9ACD32 | rgb(154, 205, 50) |
W3C Color Names Grouped by Shade
If you know the hue you want but not the name, start here. Blues and greens make up almost a third of the list, while orange has only five names.
| Shade | Count | Color names |
| Blues and cyans | 24 | aqua, cyan, lightcyan, paleturquoise, aquamarine, turquoise, mediumturquoise, darkturquoise, cadetblue, steelblue, lightsteelblue, powderblue, lightblue, skyblue, lightskyblue, deepskyblue, dodgerblue, cornflowerblue, royalblue, blue, mediumblue, darkblue, navy, midnightblue |
| Greens | 23 | greenyellow, chartreuse, lawngreen, lime, limegreen, palegreen, lightgreen, mediumspringgreen, springgreen, mediumseagreen, seagreen, forestgreen, green, darkgreen, yellowgreen, olivedrab, olive, darkolivegreen, mediumaquamarine, darkseagreen, lightseagreen, darkcyan, teal |
| Purples and violets | 19 | lavender, thistle, plum, violet, orchid, fuchsia, magenta, mediumorchid, mediumpurple, rebeccapurple, blueviolet, darkviolet, darkorchid, darkmagenta, purple, indigo, slateblue, darkslateblue, mediumslateblue |
| Browns | 17 | cornsilk, blanchedalmond, bisque, navajowhite, wheat, burlywood, tan, rosybrown, sandybrown, goldenrod, darkgoldenrod, peru, chocolate, saddlebrown, sienna, brown, maroon |
| Whites | 17 | white, snow, honeydew, mintcream, azure, aliceblue, ghostwhite, whitesmoke, seashell, beige, oldlace, floralwhite, ivory, antiquewhite, linen, lavenderblush, mistyrose |
| Grays and black | 17 | gainsboro, lightgray, lightgrey, silver, darkgray, darkgrey, gray, grey, dimgray, dimgrey, lightslategray, lightslategrey, slategray, slategrey, darkslategray, darkslategrey, black |
| Yellows | 11 | gold, yellow, lightyellow, lemonchiffon, lightgoldenrodyellow, papayawhip, moccasin, peachpuff, palegoldenrod, khaki, darkkhaki |
| Reds | 9 | indianred, lightcoral, salmon, darksalmon, lightsalmon, crimson, red, firebrick, darkred |
| Pinks | 6 | pink, lightpink, hotpink, deeppink, mediumvioletred, palevioletred |
| Oranges | 5 | coral, tomato, orangered, darkorange, orange |
Some names are misleading. darkslategray looks dark green, brown reads as a dull red, and blueviolet is closer to purple than blue. Always check the swatch, not just the name.
The 16 Basic W3C Colors
The original HTML 4 standard defined just 16 color names, sometimes called the VGA colors. CSS 2.1 added orange as the 17th, and CSS3 then adopted the larger X11-based list that grew to today’s 148.
| Color name | Hex code | RGB value |
| black | #000000 | rgb(0, 0, 0) |
| silver | #C0C0C0 | rgb(192, 192, 192) |
| gray | #808080 | rgb(128, 128, 128) |
| white | #FFFFFF | rgb(255, 255, 255) |
| maroon | #800000 | rgb(128, 0, 0) |
| red | #FF0000 | rgb(255, 0, 0) |
| purple | #800080 | rgb(128, 0, 128) |
| fuchsia | #FF00FF | rgb(255, 0, 255) |
| green | #008000 | rgb(0, 128, 0) |
| lime | #00FF00 | rgb(0, 255, 0) |
| olive | #808000 | rgb(128, 128, 0) |
| yellow | #FFFF00 | rgb(255, 255, 0) |
| navy | #000080 | rgb(0, 0, 128) |
| blue | #0000FF | rgb(0, 0, 255) |
| teal | #008080 | rgb(0, 128, 128) |
| aqua | #00FFFF | rgb(0, 255, 255) |
Notice that green is #008000, a mid green. The pure #00FF00 green is called lime. This catches many beginners out.
| Specification | Year | Named colors |
| HTML 4.01 / CSS 1 | 1996 to 1999 | 16 |
| CSS 2.1 | 2011 | 17 (adds orange) |
| CSS Color Level 3 | 2011 | 147 |
| CSS Color Level 4 | 2014 onward | 148 (adds rebeccapurple) |
Duplicate Color Names: Gray vs Grey, Aqua vs Cyan
Nine of the 148 names are aliases for a color that already has another name, which is why there are only 139 unique colors.
| Alias pair | Hex code |
| aqua = cyan | #00FFFF |
| fuchsia = magenta | #FF00FF |
| gray = grey | #808080 |
| darkgray = darkgrey | #A9A9A9 |
| dimgray = dimgrey | #696969 |
| lightgray = lightgrey | #D3D3D3 |
| slategray = slategrey | #708090 |
| lightslategray = lightslategrey | #778899 |
| darkslategray = darkslategrey | #2F4F4F |
Both spellings of gray work in every browser, so use whichever matches your team’s style. Most codebases standardize on the American gray.
Why Is darkgray Lighter Than gray?
darkgray (#A9A9A9) is noticeably lighter than gray (#808080). It is the best-known quirk in the list, and it comes from history rather than logic.
The extended names came from the X11 color system used on Unix desktops, where gray was #BEBEBE. Relative to that, X11’s darkgray really was darker. When CSS kept the HTML 4 value of #808080 for gray but imported X11’s darkgray unchanged, the two ended up in the wrong order.
W3C vs X11 Color Names
The W3C list is based on X11, but four names clash. In each case, CSS kept the older HTML 4 value.
| Name | X11 value | W3C/CSS value |
| gray | #BEBEBE | #808080 |
| green | #00FF00 | #008000 |
| maroon | #B03060 | #800000 |
| purple | #A020F0 | #800080 |
If you move colors between a Linux app and a web page, check these four by hex code rather than by name.
The Story Behind rebeccapurple
rebeccapurple (#663399) is the only named color added after CSS3, and it has a personal history. It was added in 2014 in memory of Rebecca Meyer, the daughter of CSS pioneer Eric Meyer, who died on her sixth birthday. Purple was her favorite color.
The proposal came from the web community, and the CSS Working Group accepted it into CSS Color Module Level 4. It is supported in all modern browsers.
Accessibility: Which Named Colors Are Safe for Text?
Plain red text on a white background fails WCAG AA for normal text, with a contrast ratio of only 4.0:1. A familiar name is no guarantee of readable text. WCAG 2.2 asks for at least 4.5:1 for body text and 3:1 for large text.
The ratios below were calculated with the WCAG relative luminance formula.
| Color name | Contrast on white | Contrast on black | Body text on white |
| navy | 16.01:1 | 1.31:1 | Pass (AAA) |
| midnightblue | 14.85:1 | 1.41:1 | Pass (AAA) |
| maroon | 10.95:1 | 1.92:1 | Pass (AAA) |
| darkslategray | 8.93:1 | 2.35:1 | Pass (AAA) |
| rebeccapurple | 8.41:1 | 2.50:1 | Pass (AAA) |
| darkgreen | 7.44:1 | 2.82:1 | Pass (AAA) |
| firebrick | 6.68:1 | 3.14:1 | Pass (AA) |
| dimgray | 5.49:1 | 3.83:1 | Pass (AA) |
| green | 5.14:1 | 4.09:1 | Pass (AA) |
| crimson | 4.99:1 | 4.21:1 | Pass (AA) |
| red | 4.00:1 | 5.25:1 | Fail |
| gray | 3.95:1 | 5.32:1 | Fail |
| dodgerblue | 3.24:1 | 6.49:1 | Fail |
| tomato | 2.95:1 | 7.13:1 | Fail |
| orange | 1.97:1 | 10.63:1 | Fail |
| yellow | 1.07:1 | 19.56:1 | Fail |
For error messages on white, use firebrick or crimson instead of red. For muted gray text, use dimgray instead of gray.
Named Colors vs Hex vs RGB vs HSL
All four formats produce identical results when they describe the same color. The difference is readability and control.
| Format | Example (same color) | Readability | Exact control | Transparency | Best for |
| Named color | tomato | Highest | 148 fixed values only | No | Prototypes, demos, teaching |
| Hex | #FF6347 | Low | Full sRGB range | Yes, as #RRGGBBAA | Brand colors, design handoff |
| RGB | rgb(255 99 71) | Medium | Full sRGB range | Yes | Programmatic color changes |
| HSL | hsl(9 100% 64%) | Medium | Full sRGB range | Yes | Building lighter and darker shades |
Newer formats such as oklch() cover wider color spaces than any of these, but named colors remain limited to the sRGB values listed above.
When Not to Use Named Colors
Named colors cover only 139 of the 16,777,216 colors in standard 24-bit sRGB. That limits them in three situations.
- Brand colors. Your brand blue is almost certainly not exactly royalblue. Use the hex code from your style guide.
- Design systems. Store colors as CSS custom properties, for example –color-primary: #1A73E8;, so you can change them in one place.
- Transparency. Named colors are always opaque. Use rgb() or hsl() with an alpha value instead.
There is no performance difference between a name and a hex code. Browsers resolve both to the same value instantly.
Frequently Asked Questions
How many W3C color names are there?
There are 148 W3C color names in CSS Color Module Level 4. Because nine names are aliases, such as gray and grey, they represent 139 unique colors.
What are the 16 basic W3C colors?
The 16 basic colors from HTML 4 are black, silver, gray, white, maroon, red, purple, fuchsia, green, lime, olive, yellow, navy, blue, teal and aqua.
Are CSS color names case-sensitive?
No. Red, RED and red all produce #FF0000. Lowercase is the most common convention in modern CSS.
Do W3C color names work in all browsers?
Yes. All 148 names work in every modern browser, including Chrome, Firefox, Safari and Edge, and each renders as the same fixed hex value everywhere.
Is it gray or grey in CSS?
Both are valid. Every gray name has a grey alias with an identical value, for example slategray and slategrey are both #708090.
Why is darkgray lighter than gray?
CSS kept gray at the HTML 4 value of #808080 but imported darkgray (#A9A9A9) from the X11 system, where gray was lighter. The result is that darkgray is lighter than gray.
What is the newest W3C color name?
rebeccapurple (#663399), added in 2014 in memory of Rebecca Meyer, daughter of CSS expert Eric Meyer.
Are named colors slower than hex codes?
No. Browsers convert a name to its value instantly, so there is no measurable performance difference.
Conclusion
W3C color names give you 148 readable shortcuts for common colors, all supported in every modern browser. Use them for prototypes, demos and quick styling, and switch to hex, RGB or HSL when you need exact brand colors or transparency. Bookmark the table above or download the PDF to keep the full list on hand.
READ NEXT:





