How to use the Color Converter
- Type a hex code or use the color picker.
- Read the RGB, HSL and HSV values.
- Check the contrast ratios.
Formula
HSL: hue in degrees, saturation and lightness in percent. Contrast uses WCAG relative luminance.
Worked examples
#1d4ed8
rgb(29, 78, 216)
rgb(29, 78, 216)
Frequently asked questions
What contrast ratio do I need?
4.5:1 for normal text and 3:1 for large text under WCAG AA.
Why do HSL and HSV differ?
HSL models lightness; HSV models brightness. The same color has different numbers in each.
Does hex support transparency?
This tool reads #RGB and #RRGGBB. CSS also allows #RRGGBBAA, but alpha is not handled here.