The Hex format consists of six digits of alphanumeric code and are denoted by a preceding hashtag, like this:
#3ab13f. These values can be easily copy-pasted from most design software.
For certain colors with repeating digits in the hex code, you can use a three-digit shorthand. For instance,
#333333 can be shortened to
RGB & RGBA
The RGB format consists of defined values for each of the red, green, and blue colors. It is written like this:
rgb( 13, 124, 0 ).
The RGBA format: When necessary, you can use a fourth value that denotes opacity to make the color semi-transparent. Opacity is scaled from 0–1, where 0 is completely transparent and 1 is fully opaque. An opacity of .5 is half-transparent. This is written like this:
rgba( 13, 124, 0, .5 ).
For ease of use, there are 147 colors that have human-friendly names. These include common color names like:
blue, etc., as well as some fancier ones like
There are many websites that list all named CSS colors for reference.
- Color Theory for Designers
- An Animated Guide to Hex Codes
- Building Your Color Palette
- A website color case study
- Re-Approaching Color
- A Nerd's Guide to Color