Convert hexadecimal color codes to RGB values instantly. Extract color components, preview colors, and get detailed color information.
| Format | Syntax | Value | Action |
|---|---|---|---|
| Hexadecimal | #RRGGBB | #2c7da0 | |
| RGB | RGB(r, g, b) | RGB(44, 125, 160) | |
| RGB Percentage | RGB(r%, g%, b%) | RGB(17.3%, 49.0%, 62.7%) | |
| CSS rgb() | rgb(r, g, b) | rgb(44, 125, 160) | |
| CSS rgba() | rgba(r, g, b, a) | rgba(44, 125, 160, 1) | |
| Python Tuple | (r, g, b) | (44, 125, 160) | |
| JavaScript Array | [r, g, b] | [44, 125, 160] |
These are harmonizing colors that work well with your selected color in design projects.
Hexadecimal color codes and RGB (Red, Green, Blue) are two common ways to represent colors in digital design, web development, and computer graphics.
Hexadecimal Color Codes:
Hexadecimal colors are represented by a 6-digit code prefixed with a hash (#). Each pair of digits represents the intensity of Red, Green, and Blue components:
#RRGGBB
Where RR (red), GG (green), and BB (blue) are hexadecimal values ranging from 00 to FF (0 to 255 in decimal).
RGB Color Model:
The RGB color model is an additive color model in which red, green, and blue light are added together in various ways to reproduce a broad array of colors. Each component can range from 0 to 255.
RGB(0, 0, 0) is black, RGB(255, 255, 255) is white, and RGB(255, 0, 0) is pure red.
Hex to Decimal Conversion:
Each hexadecimal digit represents 4 bits (a nibble). Two hexadecimal digits represent one byte (8 bits).
To convert a hexadecimal pair to decimal:
Decimal = (First Digit × 16) + Second Digit
Where hexadecimal digits A-F represent decimal values 10-15.
Example: Hex "2C" = (2 × 16) + 12 = 32 + 12 = 44
| Format | Example | Description | Usage |
|---|---|---|---|
| 6-digit Hex | #2c7da0 | Standard hexadecimal color code | Web design, CSS, HTML |
| 3-digit Hex | #2a8 | Shorthand for #22aa88 | CSS shorthand notation |
| RGB | RGB(44, 125, 160) | Red, Green, Blue values (0-255) | CSS, graphic design |
| RGBA | RGBA(44, 125, 160, 0.5) | RGB with alpha transparency (0-1) | CSS with transparency |
| HSL | HSL(198°, 57%, 40%) | Hue, Saturation, Lightness | CSS, intuitive color adjustment |
| HSLA | HSLA(198°, 57%, 40%, 0.5) | HSL with alpha transparency | CSS with transparency |
Additive Color Model: RGB is an additive color model used for screens. Red, green, and blue light are combined to create colors. When all three are at maximum intensity, white is produced.
Hexadecimal Notation: Base-16 numbering system using digits 0-9 and letters A-F. Each hex digit represents 4 bits, so two hex digits represent one byte (0-255 in decimal).
Color Depth: Standard RGB uses 8 bits per channel (24-bit color), allowing for 16.7 million possible colors. High color modes use 10, 12, or 16 bits per channel for greater precision.
Converter Features: