RGB color picker and color code converter
Pick a color and read its RGB, HEX, HSL, CMYK and OKLCH codes. Then look at matching colors, shades and readable pairs, right here on this page.
Color codes
This color in every format. Click a value to copy it.
The CMYK value here is a quick estimate for screens. Real print colors depend on an ICC profile, such as FOGRA39 or SWOP. Read why.
About this color
Its name, the closest web-safe color, its luminance and its feel.
Live UI preview
See the color as a button, a heading, a background and an accent.
Color harmonies
Color sets built from the hue you picked. Click a swatch to use it. You can save or export any row.
Shades, tints, tones and scales
A design system scale from 50 to 950, plus lighter, darker and grayer versions. Mix them in OKLCH or in classic RGB.
Your colors
Recent colors, favorites and saved palettes. They are stored only in this browser.
More color tools
Every tool runs in your browser and links back to the picker, so you can take a color with you from tool to tool.
- Color mixerMix colors like paint, light or ink, and find a recipe for any color.
- Color converterConvert between HEX, RGB, HSL, CMYK, OKLCH, LAB and more.
- Palette generatorMake palettes, lock the colors you like, adjust them and export them.
- Color namesBrowse and search thousands of named colors.
- Shades of colorsEvery shade of blue, red, green and more, from light to dark.
- CSS color namesAll 148 CSS color keywords with HEX and RGB, plus a name quiz.
- Contrast checkerCheck WCAG contrast and get colors that are easier to read.
- Gradient generatorBuild CSS gradients that blend colors smoothly and evenly.
- Color blindness simulatorSee images and palettes the way people with color blindness see them.
- Image color pickerPick colors and palettes from any image.
- UI color previewTest your colors on real UI parts like buttons and menus.
- Tailwind colorsThe Tailwind CSS palette, closest class for any color and custom scales.
- RAL color chartAll RAL Classic colors with HEX and RGB, a closest match finder and a house preview.
- Mood palettesDescribe a mood or brand and get a matching palette.
- Color theoryGuides to RGB, HEX, HSL, CMYK, OKLCH, harmony and accessibility.
Understanding RGB color codes
Every color on a screen is a mix of three lights: red, green and blue. An RGB color code gives the strength of each light on a scale from 0 to 255. So rgb(102, 153, 255) is 40% red, 60% green and 100% blue. That is the soft blue this page starts with. In hexadecimal, the same color is #6699FF. HEX uses two digits for each light, so HEX and RGB are just two ways to write the same value.
RGB is easy for computers but hard for people. It is tricky to make a color βa bit lighterβ by changing three numbers at once. HSL and HSV help here. They keep hue apart from saturation and lightness, and the 2D picker above works the same way. For print, you will use CMYK. For modern CSS, design systems and gradients, the OKLCH space gives smoother results that are easier to predict.
How to use this color picker
- Drag in the large square. Left and right sets saturation, and up and down sets brightness. Use the hue slider to change the base hue, and the alpha slider to set transparency.
- You can also type or paste a value into the HEX field. It takes HEX,
rgb(),hsl(),oklch(), color names likecornflowerblue, and even β102, 153, 255β. - Click any value card to copy it. The HEX, RGB, HSL and OKLCH values are valid CSS, so you can paste them right into a stylesheet.
- Scroll down to find matching colors, a design system scale from 50 to 950, and tints, shades and tones. Save any row as a palette, or export it as CSS, JSON or Tailwind.
- Use the link button to share the exact color. Every color has its own page at
/color/HEX. Thousands of colors also have names, which you can browse in the color library.
Frequently asked questions
What is an RGB color code?
An RGB color code tells you how much red, green and blue light a color has. Each one goes from 0 to 255. For example, rgb(102, 153, 255) has a little red, more green and full blue, which makes a sky blue. Screens add these three lights together. So rgb(255, 255, 255) is white and rgb(0, 0, 0) is black.
How do I convert RGB to HEX?
Write each RGB number as a two-digit hexadecimal number. Then join them after a #. 102 becomes 66, 153 becomes 99 and 255 becomes FF, so rgb(102, 153, 255) is #6699FF. The picker above does this for you. The converter also goes the other way (HEX to RGB) and handles HSL, CMYK, OKLCH and more.
What is the difference between HSL and HSV?
Both use hue and saturation. The third value is what sets them apart. In HSL it is lightness: 50% is the pure hue and 100% is white. In HSV it is value, or brightness: 100% is the brightest form of the hue, and you get white by lowering saturation. CSS uses HSL. Many design apps use HSV in their color pickers.
Why does the CMYK value say it is approximate?
Printed color depends on the ink, the paper and the press. An ICC profile describes all of these. The CMYK shown here comes from a simple formula with no profile. That is fine as a guide, but not for real print jobs. Before you send files to a printer, convert them in your print software with the right profile.
Is anything uploaded when I pick colors or extract them from images?
No. All color math, image work and saved favorites stay in your browser. Nothing is sent to a server, and you don't need an account.
Many thanks for the support
Buy YouTube subscribers, views, likes, comments, and shares from Socialboom with secure checkout, no YouTube password required, and easy order tracking from one dashboard.
Play the new Snake Jungle game online.
The Real-Time HTML Editor is there to help you convert documents and to edit HTML easily.
