How to define a color value?

Color value:

HTML colors are defined using a hexadecimal (hex) notation. The hexadecimal value combines Red, Green, and Blue color values (RGB). The lowest value is 0 (hex 00). The highest value is 255 (hex FF).

 

Hex values are written as three double-digit numbers, starting with a # sign, such as #01EEFF.

 

The following table lists the color name, hex color values and rgb color values.

 

COLOR  HEXCOLOR  RGB COLOR

Black  #000000  rgb(0,0,0)

Red  #FF0000  rgb(255,0,0)

Green  #00FF00  rgb(0,255,0)

Blue  #0000FF  rgb(0,0,255)

Yellow  #FFFF00  rgb(255,255,0)

Cyan  #00FFFF  rgb(0,255,255)

Magenta  #FF00FF  rgb(255,0,255)

Gray  #C0C0C0  rgb(192,192,192)

White  #FFFFFF  rgb(255,255,255)

 

 

 

     

    Color set by using hex value 

     

     

    Color set by using rgb value 

     

     

    Color set by using color name