Color code converter
Convert HEX, RGB and HSL color codes and check contrastNo sign-up. What you type never leaves this browser
Color code converter
Result
Enter values to see the result.
FAQ
Are HEX and RGB the same color?
Yes, the same color written in hexadecimal and decimal. #ff0000 is rgb(255, 0, 0).
Why check contrast?
Low contrast between text and background is hard to read. WCAG recommends at least 4.5:1 for body text.
About this tool
This tool reads a color as RGB, converts it to HEX, RGB and HSL, and works out contrast ratios against white and black text using WCAG 2 relative luminance.
- Reads #rgb, #rrggbb, rgb(r, g, b) and hsl(h, s%, l%).
- A ratio of 4.5:1 or more passes AA for body text, 7:1 AAA, and 3:1 AA for large text only.
- The color picker updates the code field.
What you enter is worked out only in this browser and never sent to a server. Nothing you type is stored; only the lists of recently used and favorite tools stay in this browser.