Hex to RGB Color Converter
Enter 6 digits hex color code and press the Convert button:
Hex to RGB color table
| Color | Color name |
Hex | (R,G,B) |
|---|---|---|---|
| Black | (0,0,0) | ||
| White | (255,255,255) | ||
| Red | (255,0,0) | ||
| Lime | (0,255,0) | ||
| Blue | (0,0,255) | ||
| Yellow | #FFFF00 | (255,255,0) | |
| Cyan | #00FFFF | (0,255,255) | |
| Magenta | #FF00FF | (255,0,255) | |
| Silver | #C0C0C0 | (192,192,192) | |
| Gray | #808080 | (128,128,128) | |
| Maroon | #800000 | (128,0,0) | |
| Olive | #808000 | (128,128,0) | |
| Green | #008000 | (0,128,0) | |
| Purple | #800080 | (128,0,128) | |
| Teal | #008080 | (0,128,128) | |
| Navy | #000080 | (0,0,128) |
Hex to RGB conversion
- Get the 2 left digits of the hex color code and convert to decimal value to get the red color level.
- Get the 2 middle digits of the hex color code and convert to decimal value to get the green color level.
- Get the 2 right digits of the hex color code and convert to decimal value to get the blue color level.
Example #1
Convert red hex color code FF0000 to RGB color:
Hex = FF0000
So the RGB colors are:
R = FF16 = 25510
G = 0016 = 010
B = 0016 = 010
Or
RGB = (255, 0, 0)
Example #2
Convert gold hex color code FFD700 to RGB color:
Hex = FFD700
So the RGB colors are:
R = FF16 = 25510
G = D716 = 21510
B = 0016 = 010
Or
RGB = (255, 215, 0)
Additional explanations and examples
How to convert hex to RGB color
How to convert from hexadecimal color code to RGB color.
Hex color code
Hex color code is a 6 digits hexadecimal (base 16) number:
RRGGBB16
The 2 left digits represent the red color.
The 2 middle digits represent the green color.
The 2 right digits represent the blue color.
RGB color
The RGB color is a combination of Red, Green and Blue colors:
(R, G, B)
The red, green and blue use 8 bits each, which have integer values from 0 to 255.
So the number of colors that can be generated is:
256×256×256 = 16777216 = 100000016
Hex to RGB conversion
- Get the 2 left digits of the hex color code and convert to decimal value to get the red color level.
- Get the 2 middle digits of the hex color code and convert to decimal value to get the green color level.
- Get the 2 right digits of the hex color code and convert to decimal value to get the blue color level.
Example #1
Convert red hex color code FF0000 to RGB color:
Hex = FF0000
So the RGB colors are:
R = FF16 = 25510
G = 0016 = 010
B = 0016 = 010
Or
RGB = (255, 0, 0)
Example #2
Convert gold hex color code FFD700 to RGB color:
Hex = FFD700
So the RGB colors are:
R = FF16 = 25510
G = D716 = 21510
B = 0016 = 010
Or
RGB = (255, 215, 0)