HohoTools
中文

HEX to RGB Converter

This free HEX to RGB converter turns any hex color code into its red, green and blue channels the moment you type it.

How to use

  1. Type or paste a hex color — with or without the # and in 3- or 6-digit form.
  2. The red, green and blue channels appear instantly, each as a number from 0 to 255.
  3. Copy the ready-to-paste rgb() CSS snippet with one click.
ADAdvertisement — this space keeps HohoTools free

Frequently asked questions

What is the difference between HEX and RGB?

Nothing but notation. #FFA500, rgb(255, 165, 0) and the named orange all describe the same color: each hex pair is one channel written in base 16 (FF = 255, A5 = 165, 00 = 0). Pick whichever your tool, framework or teammate expects — converters like this one translate losslessly in both directions.

Does the 3-digit shorthand work?

Yes. A three-digit hex like #fff is standard CSS shorthand where each digit is doubled: f expands to ff, so #fff equals #ffffff and converts to rgb(255, 255, 255). The leading hash is optional — fff and ffffff both work.

Do you support 8-digit hex with alpha transparency?

No, and this is deliberate: rgb() notation with transparency uses the separate rgba() syntax, and this tool converts opaque colors only. An 8-digit input is rejected with a clear error rather than silently dropping the alpha channel, which would produce a misleading color.

Is my color uploaded anywhere?

No. The conversion is computed locally in your browser the moment you type. Nothing leaves your device, and the result disappears when you close the page.

Related tools

About this tool

This free HEX to RGB converter turns any hex color code into its red, green and blue channels the moment you type it. HEX and RGB are two spellings of the same color: designers hand off palettes as #FFA500 while CSS also accepts rgb(255, 165, 0), and every renderer treats them identically — but the moment you need to animate a channel, blend colors in JavaScript or feed a library that expects numbers instead of strings, you need the decimal values. Type a six-digit code like #FFA500, a three-digit shorthand like fff (expanded to ffffff by the standard CSS rule), with or without the leading hash — the converter accepts them all and shows each channel as a number from 0 to 255 together with a ready-to-paste rgb() CSS snippet. Invalid input is rejected outright with a clear message instead of silently producing a wrong color, so a typo can never sneak a broken value into your stylesheet. The conversion runs entirely in your browser on your own device: nothing you type is uploaded, stored or logged. Paste a hex code below and copy the RGB you need.