Color Code Converter

Convert between HEX, RGB, and HSL, preview colors, check WCAG contrast, and explore color harmonies.

%
%
HEX#ff0000
RGBrgb(255, 0, 0)
RGBArgba(255, 0, 0, 1.00)
HSLhsl(0, 100%, 50%)
HSLAhsla(0, 100%, 50%, 1.00)
Closest Tailwind Classred-600 (#e7000b)
Preview

WCAG Contrast

Aa

vs. White: 4.00

AA (Normal Text)Fail
AAA (Normal Text)Fail
AA (Large Text)Pass
Aa

vs. Black: 5.25

AA (Normal Text)Pass
AAA (Normal Text)Fail
AA (Large Text)Pass

Color Harmony

Complementary
Analogous
Triadic
Monochromatic

This tool is for digital displays (light-based RGB); print production needs a dedicated CMYK tool.

WCAG contrast ratios are calculated against pure white and pure black backgrounds using the standard relative luminance formula.

All calculations run locally in your browser; nothing is sent to external servers.