Tools38

Translate codes

RGB to HEX Converter.

Convert RGB channel values to clean 6-digit HEX codes alongside OKLCH, HSL, and CMYK.

Export palette

Import colors

Paste CSS variables, JSON tokens, a Coolors URL, or comma-separated HEX / RGB / OKLCH values (3–8 colors).

Try:

Saved Palettes

Stored in your browser cache—no account required.

Blog How to convert RGB (0–255) color values to HEX Read the guide

Convert RGB (0–255) color values to 6-digit HEX codes and CSS formats

Enter rgb(r, g, b) values to get the exact uppercase #RRGGBB hexadecimal code, perceptual OKLCH, HSL, CIELAB, CMYK, and nearest Tailwind/RAL tokens in real time.

Instant 24-bit RGB ↔ HEX color code translator.
QUICK VIDEO TUTORIAL How to convert RGB (0–255) color values to HEX Translate Red, Green, and Blue integers into 6-digit hexadecimal and CSS Color 4 codes. Watch the video

How to convert RGB (0–255) color values to HEX

Fast, clutter-free code translation

Web & Mobile

24-bit sRGB precision

Converts 0–255 red, green, and blue channels to exact two-digit hex bytes.

CSS & Canvas

Bidirectional editing

Paste rgb(50, 146, 133) or #329285 in the top omnibox or inline cells.

Token Lookup

Tailwind & RAL bonus

Immediately see the closest Tailwind CSS v4 class and Classic RAL standard.

Key capabilities

6 live bidirectional color spaces

Converts simultaneously between HEX, OKLCH, RGB, HSL, D65 CIELAB, and process CMYK.

Omnibox parsing

Type or paste in any card—or drag perceptual OKLCH sliders—to update all six spaces in real time.

Porter-Duff & inverse alpha math

Flattens RGBA over any backdrop into opaque HEX and solves exact opacity for target tints.

Zero bleed

Side-by-side proof confirms 0.0 ΔE visual match between RGBA and solid HEX.

Closest Tailwind v4 & Classic RAL

Finds nearest official Tailwind CSS tokens and Classic RAL paint standards with perceptual ΔE scores.

Split swatch proof

Each match row displays a 50/50 split swatch and exact ΔE perceptual distance for visual verification.

Synced active palette across tools

Move freely between Generator, Visualizer, Contrast, Tailwind, and Vision without re-entering colors.

How state travels

Your active palette syncs automatically in browser storage across every module, and visiting any tool directly starts from a fresh harmonious palette.

Formats & privacy

Supported inputs
sRGB 0–255 Channel Values or rgb(r, g, b)
Outputs & exports
Uppercase 6-Digit #HEX Code + OKLCH, HSL & CMYK

Supports 3 to 8 active palette roles with unlimited local saves and exports—no account required.

All color math, simulations, and exports run locally in your browser while syncing your active palette across tools.

FAQ

Good to know.

A few answers before you get started.

On your device
How is rgb(200, 30, 81) converted to #C81E51?

Each integer from 0 to 255 is written in base-16 with two digits: 200 = C8, 30 = 1E, and 81 = 51.

How are RGB 0–255 numbers converted to a 6-digit HEX string?

Each integer channel (Red, Green, Blue from 0 to 255) is converted to base-16 (00 through FF) and concatenated—for example rgb(200, 30, 81) becomes #C81E51.

Can I type bare comma-separated numbers like 200, 30, 81?

Yes. The RGB input box accepts rgb(200, 30, 81), space-separated rgb(200 30 81), or plain 200, 30, 81.

Does it also show HSL, OKLCH, and CMYK at the same time?

Yes. Every color model updates live in the conversion ledger alongside nearest Tailwind v4 and Classic RAL matches.

Language38

EnglishالعربيةFrançaisItalianoDeutschEspañolPortuguêsNederlandsРусскийTürkçe日本語中文हिन्दीBahasa IndonesiaBahasa Melayu한국어Tiếng ViệtไทยPolskiSvenskaУкраїнськаNorskবাংলাΕλληνικάفارسیاردوČeštinaDanskMagyarRomânăSuomiБългарскиFilipinoქართულიSlovenčinaAzərbaycancaעבריתSlovenščina