Skip to content
UBIS Tool

Color Code Converter

Convert between HEX, RGB, HSL, and CMYK and check text contrast.

Color input

Formats

HEX
RGB
HSL
HSV
CMYK

Text contrast (WCAG)

At least 4.5:1 is recommended for normal text and 3:1 for large text.

How to use

  1. 01

    Enter a color

    Type a code such as #3159D9, rgb(49, 89, 217), or hsl(226, 69%, 52%), or use the picker.

  2. 02

    Check the values

    HEX, RGB, HSL, HSV, and CMYK values appear instantly.

  3. 03

    Copy and check contrast

    Copy the value you need and check contrast with white and black text.

Try a small example

Input

Enter #336699.

Try this

Look at the RGB result.

What to check

The channels read red 51, green 102, and blue 153.

Troubleshooting

Printed colors differ from the screen.

CMYK is a simple conversion. Real print colors depend on paper, ink, and color profiles.

The code is not recognized.

HEX (3, 4, 6, or 8 digits), rgb()/rgba(), and hsl()/hsla() are supported. Color names such as red are not.

Related tools

Frequently asked questions

What contrast ratio is enough?

WCAG recommends at least 4.5:1 for normal text and 3:1 for large text.

Important information

Your input is processed only in your browser and is not stored or sent.