Color Code Converter
Type any format, e.g. #2F6B3F, rgb(47,107,63), hsl(136 39% 30%) or a color name.
Text contrast (WCAG 2.x)
Lighter & darker
Every color format at once
Moving a color from a design mockup to the web, from a website to print, or a brand color into a document means converting between HEX, RGB, HSL and CMYK. Type a color in any format and see all formats together. Use the color picker to choose visually, and click Copy next to any value.
Formats
- HEX — like #2F6B3F: red, green and blue as two hex digits each. The standard for web and design tools; 3-digit shorthand like #2F3 works too.
- RGB — red, green, blue from 0 to 255, used in Office's custom color dialogs.
- HSL / HSV — hue (0–360°), saturation and lightness/value, which make “same color, a bit lighter” easy.
- CMYK — ink percentages for print. It's a simple formula from screen RGB for reference; real print colors depend on the printer's color management (ICC profiles).
Contrast check
Contrast between the color and white or black text is calculated with the WCAG 2.x formula. Normal text needs 4.5:1 (AA), the stricter level 7:1 (AAA), and large text 3:1. It tells you instantly which text color reads better on a button or banner.
“Lighter & darker” lists shades that keep the hue and saturation and change lightness in 10% steps — useful for hover states or pale backgrounds. To build a full color scheme, use Color Palette Generator.
Frequently asked questions
What about transparency (alpha)?
rgba and hsla are accepted, but only the color is read; alpha is ignored.
Do color names work?
Yes — every CSS color name your browser knows (red, navy, rebeccapurple…).
Can it convert to Pantone?
No. Pantone is a licensed color system.
Related tools
- Color Palette GeneratorComplementary, analogous, triadic and monochrome palettes from one color, or extract colors from a photo
- Favicon GeneratorText, emoji or logo → favicon.ico, 16–512 px PNGs, Apple touch icon and web manifest in a ZIP
- Add Text to PhotoPut a caption on a photo and drag it into place — font, size, color, outline, banner
- JSON Formatter & ValidatorPretty-print JSON, pinpoint errors, minify, sort keys, escape/unescape strings
- Regex TesterHighlight matches, see capture groups, preview replacements, common patterns
- Base64 Encode / DecodeText (UTF-8) ↔ Base64, files and images → data URI, Base64 → file