Convert RGB color to Hex Web html color
Convert RGB color to Hex code (Web html) color, free and easy to use color converter tool. You enter code for Red, Green and Blue click the convert button and get the html code for your color.
How to use RGB to Hex converter:
Enter R,G,B values between 0-255 each (e.g. "38,171,241") and click on the convert button to get its equivalent Hex six-digit number format (e.g. "#26ABF1") .
RGB RedGreedBlue colors
RGB color model stand for: R for Red, G for Green, and B for Blue. Computer representation is using 8 bits for each color with values beteen 0 to 255. RGB vlaues indicating how much of each of the red, green, and blue is included in the restult color. Combination of different saturatation of the three values create a range of colors where 255 defined maximum streng and zero none. If all the three values are set to 255 the result color is black, And if all are set to Zero, the result is white.How to convert RGB to Hex
To convert from RGB number format to Hexadecimal number format we need to convert the number from RGB Decimal base which is a count base of 10 to Hex base which is a count base of 16.
The Hexadecimal counting system is using the same 10 digits from 0 to 9,
And for the value over 9 it uses the letters A to F to keep the value presented with only one digit.
The Decimal counting system is using 10 digint from 0 to 9
(92)₁₆ = (9 × 10¹) + (2 × 10⁰) = (92)₁₀
Decimal to Hexadecimal value
Dec | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |
Hex | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | A | B | C | D | E | F |
Hexadecimal number is the sum of the digits multiplied (×) by 16 power by the digit possition (D³). If the same number (1825) was in Hexadecimal base it's values will be: (1825)₁₆ = (1 × 16³) + (8 × 16²) + (2 × 16¹) + (5 × 16⁰) = (6181)₁₀
Example
Let's take the RGB color format 19,213,254 and convert it to Hex step by step:We will convert the two left digits '19' of the Red color from decimal base to hex base as follow:
(19)₁₀ = (19 / 16) = (1 × 16¹)₁₆ and left (3 × 16⁰)₁₆ =(13)₁₆
We will convert the two middle digits '213' of the Green color from decimal base to hex base as follow:
(213)₁₀ = (213 / 16) = (13 × 16¹)₁₆ and left (5 × 16⁰)₁₆ =(D5)₁₆
* 13 in Dec base is D in hex base
We will convert the two right digits '254' of the Blue color from decimal base to hex base as follow:
(254)₁₀ = (254 / 16) = (15 × 16¹)₁₆ and left (14 × 16⁰)₁₆ =(FE)₁₆
* 15 in Dec base is F in hex base is , And 14 in Dec base is E in hex base
The Red,Green,Blue format color19,213,254 converted to #13D5FE hex color code.
Convert Hex to RGB color format
Views
1802
|
Replies
0
|
Likes
0
|