RGB Color Picker
Mix red, green and blue with the sliders and copy the colour in any format.
- HEX
- #D81B60
- RGB
- rgb(216, 27, 96)
- HSL
- hsl(338, 78%, 48%)
- CMYK
- cmyk(0%, 88%, 56%, 15%)
White text on it: 4.95:1, passes WCAG AA. Black text on it: 4.25:1, passes WCAG AA for large text only.
How RGB colours work
Screens make every colour from red, green and blue light. Each channel runs from 0 (off) to 255 (full), so rgb(0, 0, 0) is black, rgb(255, 255, 255) is white and rgb(255, 0, 0) is pure red.
That gives 256 × 256 × 256, or about 16.7 million, colours. In CSS you write them as rgb(216, 27, 96); add a fourth value, as in rgb(216 27 96 / 50%), for transparency.
Questions
How do I get the RGB value of a colour on a web page?
Use the free AutoColorPicker Chrome extension: click Pick a color, then click the colour on the page to copy its RGB and HEX values.
What is the difference between RGB and CMYK?
RGB mixes light for screens. CMYK mixes cyan, magenta, yellow and black ink for print, so some bright screen colours can't be printed exactly.
How do I convert RGB to HEX?
Turn each of the three numbers into a two-digit hexadecimal value and join them after a #. This page does it for you as you move the sliders.
Pick colours straight from any website
The free AutoColorPicker extension reads the HEX and RGB of any pixel on a page in one click.