Hex to RGB Converter
To convert hex to RGB, split the six hex digits into three pairs — red, green, blue — and read each pair as a decimal number from 0 to 255. For example, #FF5733 is rgb(255, 87, 51).
Convert any hex color code to RGB values instantly. Type a hex code like #FF5733 and get rgb(255, 87, 51) with one click to copy.
How hex to RGB conversion works
A hex code is just RGB written in hexadecimal. The first two digits are red, the middle two are green, and the last two are blue. Each pair runs from 00 (none) to FF (full, 255 in decimal). So #FF5733 means red = FF = 255, green = 57 = 87, blue = 33 = 51, giving rgb(255, 87, 51). Three-digit codes like #F53 are shorthand: each digit is doubled, so #F53 is the same as #FF5533.
RGB is the format most design tools and CSS functions like rgb() and rgba() use when you need to add transparency — rgba(255, 87, 51, 0.5) is the same color at 50% opacity.
Frequently asked questions
What is the RGB of #FF0000?
The RGB of #FF0000 is rgb(255, 0, 0) — full red, no green, no blue.
How do I convert a 3-digit hex like #F53 to RGB?
Double each digit first: #F53 becomes #FF5533, which is rgb(255, 85, 51).
Can I use RGB values in CSS?
Yes. Write color: rgb(255, 87, 51); in CSS, or add a fourth number for transparency: rgba(255, 87, 51, 0.5).
Related tools
Color Converter (all formats) · Hex to RGB · RGB to Hex · Hex to HSL · HSL to Hex · Color Picker