Compare HEX and RGB values for the same color.
The HEX to RGB and RGB to HEX Converter changes between color notations such as #FF0000 and rgb(255, 0, 0). Use the Hex and RGB fields to compare a design color with the value your stylesheet expects.
A six-digit HEX color has two digits for each channel. Each pair maps to a number from 0 to 255:
Red uses the first pair, such as FF = 255.
Green uses the middle pair, such as 00 = 0.
Blue uses the last pair, such as 00 = 0.
For example, #FF0000 corresponds to rgb(255, 0, 0), or pure red.
Enter a color in Hex or RGB.
Review the corresponding value in the other field.
Select and copy the notation you need for your project.
CSS shorthand such as #F00 and an alpha-bearing value such as #FF000080 are different input forms. Check whether the field accepts the syntax you have, rather than assuming all HEX lengths are supported.
Transparency can also use rgba() with alpha from 0 to 1. This interface does not show a separate alpha control. Other CSS notations, including hsl() and oklch(), are outside the two fields shown here.
Review the converted value in your actual stylesheet and background. Changing notation does not check contrast or make a color accessible.
How to Use HEX to RGB and RGB to HEX Converter
Type a color into the matching Hex or RGB field. Use a syntax the input accepts.
Review the other value, then select and copy it. Check transparency separately if your source includes alpha.
Compare HEX and RGB values for the same color.
Tool Use:
625Added:
Jul 6, 2023Type:
Free ToolPrivacy:
Client SideColor name finder for HEX, RGB, RGBA, HSL, or a color picker. Find the closest CSS-named match and copy the color codes you need.
Choose a color and copy its HEX, RGB, or HSL value.
Color contrast checker for foreground and background colors. Review the contrast ratio, AA and AAA text thresholds, and the visual preview.