Color Converter

Convert between HEX, RGB, HSL and CSS colour names, with the contrast ratio against black and white.

Colour · example: #1f5eff → rgb(31, 94, 255) / hsl(223, 100%, 56%)

How it works

Conversion is exact where the target space can represent the value and rounds only for display, so a HEX → RGB → HEX round trip returns the original value.

The contrast figures use the WCAG relative-luminance formula against `#000` and `#fff`, which is the check that decides whether light or dark text belongs on the colour.

This tool runs entirely in your browser. NextName does not receive or store what you paste.