Pick any color and instantly convert between HEX, RGB, HSL, HSB and CMYK formats. Get color shades, check contrast ratios for accessibility, and copy any value with one click.
Different industries and tools use different color formats. Knowing when to use which format saves time and prevents color mismatches between design and code.
Hexadecimal color codes are the most common format in web development. A hex code like #f43f5e represents red, green, and blue values in base-16. Used in HTML, CSS, and most design tools.
RGB (Red, Green, Blue) describes colours as three values from 0–255. rgb(225, 29, 72) is the same as #e11d48. Used in web design and on screens.
HSL (Hue, Saturation, Lightness) is the most human-readable format. Hue is the color angle (0–360°), saturation is intensity (0–100%), lightness is brightness (0–100%). Great for creating color variations programmatically.
CMYK (Cyan, Magenta, Yellow, Key/Black) is used in print design. Screens use RGB light mixing while printers use CMYK ink mixing. Always convert to CMYK before sending designs to print.
Web Content Accessibility Guidelines (WCAG) define minimum contrast ratios to ensure text is readable for people with visual impairments.
| Level | Normal Text | Large Text |
|---|---|---|
| WCAG AA | 4.5:1 | 3:1 |
| WCAG AAA | 7:1 | 4.5:1 |
| Fail | Below 4.5:1 | Below 3:1 |
Large text is defined as 18pt (24px) or 14pt (18.67px) bold. UI components and decorative elements are exempt from contrast requirements.
| Format | Best For |
|---|---|
| HEX | Web CSS, HTML, Figma, Sketch |
| RGB | Web design, screens |
| HSL | CSS variables, dynamic theming |
| HSB | Photoshop, Illustrator color picker |
| CMYK | Print, InDesign, Corel Draw |
Colors on the web are commonly represented in three interchangeable formats: HEX (like #3b82f6), RGB (red, green, blue values from 0–255), and HSL (hue, saturation, lightness) — each useful in different situations. HEX is compact and common in CSS, RGB maps directly to how screens render color, and HSL is often the most intuitive for adjusting a color's shade or brightness manually.
When choosing colors for text and backgrounds, contrast matters for accessibility — the WCAG guidelines recommend a contrast ratio of at least 4.5:1 for normal body text against its background to remain readable for users with low vision. Use the picked color values directly in your CSS with the copy buttons provided.
Everything about color formats and conversion