liveBook · Manning

RGB

As explained in Web Design Playground, Second Edition

An RGB code is a color representation that specifies red, green, and blue component values.

RGB represents a color by mixing red, green, and blue. Give each component a value from 0 to 255, or a percentage from 0 to 100: smaller numbers mean less intensity, larger numbers mean more. section 17.1

Combine the three channels to see how RGB behaves:

  • One nonzero channel produces a pure color: (255, 0, 0) is red. section 17.1
  • Two full-strength channels blend: red plus green makes yellow, red plus blue makes magenta, and green plus blue makes cyan. section 17.1
  • Equal channel values create grayscale: (0, 0, 0) is black, (128, 128, 128) is gray, and (255, 255, 255) is white. section 17.1
  • With 256 values for each channel, RGB offers more than 16 million possible colors. section 17.1

How Web Design Playground, Second Edition covers it

How deep it goes
Explains channel mixing, grayscale, and palette size, but stops short of deeper color theory.
Examples
Uses common-color tables, overlapping RGB circles, pure channels, blends, and grayscale values.
What you can do after
Apply RGB values through an rgb() function or RGB code when choosing CSS colors.
How it connects
Connects RGB with CSS colors, color schemes, gradients, and HSL functions.

Also explained in

Compare how 5 books explain RGB →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Web Design Playground, Second Edition. The section links point to the parts of the book it draws on.