Key Concepts

Review core concepts you need to learn to master this subject

Color Name Keywords

h1 { color: aqua; } li { color: khaki; }

Color name keywords can be used to set color property values for elements in CSS.

Color
Lesson 1 of 1
  1. 1
    CSS supports a wide variety of colors. These include named colors, like blue, black, and limegreen, along with colors described by a numeric value. Using a numeric system allows us to take advant…
  2. 2
    Before discussing the specifics of color, it’s important to make two distinctions about color. Color can affect the following design aspects: * The foreground color * The background color Foregrou…
  3. 3
    One syntax that we can use to specify colors is called hexadecimal. Colors specified using this system are called hex colors. A hex color begins with a hash character (#) which is followed by t…
  4. 4
    There is another syntax for representing RGB values, commonly referred to as “RGB value” or just “RGB”, that uses decimal numbers rather than hexadecimal numbers, and it looks like this: h1 { co…
  5. 5
    The hexadecimal and rgb color system can represent many more colors than the small set of CSS named colors. We can use this new set of colors to refine our web page’s style. In both hex and RGB, w…
  6. 6
    The RGB color scheme is convenient because it’s very close to how computers represent colors internally. There’s another equally powerful system in CSS called the hue-saturation-lightness color sch…
  7. 7
    All of the colors we’ve seen so far have been opaque, or non-transparent. When we overlap two opaque elements, nothing from the bottom element shows through the top element. In this exercise, we’ll…
  8. 8
    We’ve completed our extensive tour of the colors in CSS! Let’s review the key information we’ve learned. There are four ways to represent color in CSS: * Named colors—there are more than 140…

What you'll create

Portfolio projects that showcase your new skills

Pro Logo

How you'll master it

Stress-test your knowledge with quizzes that help commit syntax to memory

Pro Logo