RGB to HEX Converter
Enter RGB values (0-255) to convert them to a hex color code. Results update automatically.
Result
RGBrgb(255, 87, 51)
HEX
#FF5733
What RGB Values Represent
RGB (Red, Green, Blue) is an additive color model where each color is represented by three numbers from 0 to 255. RGB(255, 0, 0) is pure red, RGB(0, 255, 0) is pure green, and RGB(0, 0, 255) is pure blue. Combining all three at maximum creates white.
How to Convert RGB to HEX
RGB values represent colors using red, green, and blue components, each ranging from 0 to 255. To convert to HEX, convert each decimal value to hexadecimal and combine them with a hash prefix. For example, RGB(255, 87, 51) becomes #FF5733.
Example RGB Conversion
- RGB(255, 0, 0) → #FF0000 - Red
- RGB(0, 255, 0) → #00FF00 - Green
- RGB(0, 0, 255) → #0000FF - Blue
- RGB(255, 255, 0) → #FFFF00 - Yellow
- RGB(128, 128, 128) → #808080 - Gray
Need the reverse conversion? Try HEX to RGB converter