Hex Codes

What are hex codes? In short, hex codes are 6 digit, 3 byte hexadecimal number used to represent a color. As you may know, all colors contain three primary colors: red, green, and blue. No matter what the color is, it contains those three colors in varying degrees (yes, none counts as a ‘degree’). This would be normally represented by the RBG color model, which uses numbers for each of the colors. Each number goes up to 255, standing for how much of each color there is. 255, 0 ,0 would be red, as 255 of red and 0 of everything else, is, red.
However, you can’t always type .class {background: rgb(255,0,0); color: rgb(0,0,0);}, can you? No, and not only is it inconvenient, it doesn’t even exist, unless I claim some kind’ve of patent for it and put it in CSS 4.0, which, is the same as not happening. That’s why there are hex codes, to replace it. Instead of 255, 0 ,0, it’s #FF0000. FF stands for red, the first two digits, and blue and green are set to zero, which in hex code is double zero, to maximize the number of combinations.
Luckily, we don’t have to convert RGB to hex code in our head, because there are useful hex codes guides and lists, among other tools on the internet now. To check them out, visit the links at the bottom of this tutorial. Hope you enjoyed reading it!
Links:
Hex Code Generator (RGB > Hex Code)
Tutorial copyright Discuss Admin & Amazing Board, unauthorized reproductions not permitted