Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I recommend that you follow the W3C recommendations:</p> <p>All of them (CSS Level 1, Level 2 and Level 3) indicate that using color names is perfectly acceptable, but which ones are acceptible varies depending on the specification.</p> <h2>CSS1 Specification</h2> <p><a href="http://www.w3.org/TR/REC-CSS1/#color-units" rel="nofollow noreferrer">CSS1 Specification</a> recommends to use <strong>color names</strong> as a valid substitute to hex codes and RGB codes.</p> <blockquote> <p><strong>6.3 Color units</strong></p> <p>The suggested list of keyword color names is: aqua, black, blue, fuchsia, gray, green, lime, maroon, navy, olive, purple, red, silver, teal, white, and yellow. These <strong>16 colors</strong> are taken from the Windows VGA palette, and their RGB values are not defined in this specification.</p> </blockquote> <h2>CSS2 Specification</h2> <p>You can use the color name <code>orange</code> now! The count is up to <strong>17 colors</strong>. <a href="http://www.w3.org/TR/CSS21/syndata.html#color-units" rel="nofollow noreferrer">CSS2 Specification</a> for reference.</p> <h2>CSS3 &amp; X11 Colors</h2> <p>CSS3 allows for SVG 1.0's <a href="http://www.w3.org/TR/css3-color/#svg-color" rel="nofollow noreferrer"><strong>X11 colors</strong></a> to be used for CSS's properties (as well as <code>hsl()</code> values). This expands the amount of color names to <strong>147 colors</strong>. Any of these color names can be used in any browser that supports the SVG 1.0 specification, which is <a href="http://caniuse.com/#search=svg" rel="nofollow noreferrer">IE9 or newer</a>.</p> <p>This also means that the list of colors provided in the question are mostly <strong><em>not valid</em></strong>.</p> <h2>Suggested Usage</h2> <p>If you're seeking to support legacy browsers stick to the web safe original 16 color names since X11 colors are not supported. Otherwise, you are free to use any of the 147 color names specified in the X11 spec.</p> <p>All browsers should abide by the specification in reference to the equivalent hex codes. The time it takes the parser to read the color names is virtually, if not exactly, the same as using a hex value, an rgb value, or an hsl() value.</p> <p>To me, it's more readable to write your HEX codes in lowercase. For example, #8b88b6 is obviously more readable than #8B88B6. Also, I tend to use shorthand HEX color instead of full code (#666 instead of #666666) since it's more efficient.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload