Skip to content
Color Codes

Free color tools for designers & developers

HTML color codes in every format

Type or pick any color to get Hex, RGB, HSL and OKLCH instantly — then check contrast, build shades and find a palette that fits.

Hex, rgb(), hsl() or a CSS name

≈ SlateBlue
#5B45F5
5.81:1 on white3.61:1 on black

Studio

Tools for every color task

Pick, convert, check and generate. Every tool runs instantly in your browser.

See all tools

Palettes

Start from a palette

Curated four-color palettes for websites, apps and brands. Click a swatch to copy it.

Browse all palettes

Color formats

What are HTML color codes?

Color codes describe colors in a format browsers can read. Each format suits a different job.

HEX

Six hexadecimal digits for red, green and blue — the most common way to write colors in CSS and design tools.

RGB

Red, green and blue channels from 0 to 255, with optional alpha for transparency.

HSL

Hue, saturation and lightness — an intuitive way to create lighter, darker or muted variations.

OKLCH

A perceptual model where equal steps look equal — ideal for modern design systems.

Guides

Learn by doing

Short, practical articles on CSS color, contrast and formats — each linked to a tool.

All guides