Random Color Generator

#7040e2 Color

Color Codes
Hex Code #7040e2
RGB Code rgb(112, 64, 226)
HSL Code hsl(258, 74%, 57%)

#7040e2 Color Syntax

rgb()

 rgb(Red, Green, Blue);
 rgba(Red, Green, Blue, Alpha);

 main {
    background-color: rgb(112, 64, 226);
   }

R(red), G(green), B(blue) can be number between 0-255.
A parameter is a hex characters (0–9, A–F) and optional.

hsl()

 hsl(hue saturation lightness);
 hsl(hue saturation lightness / alpha);

 div {
  background-color: hsl(258, 74%, 57%);
  }

Saturation value is a percentage value between 0% unsaturated and 100% fully saturated.
Lightness value is a percentage value between 100% is white and 0% is black.

Lighter and darker colors of #7040e2

RGB Code Hex Code Preview
rgb(112, 64, 226, 10%) #7040e21a  
rgb(112, 64, 226, 20%) #7040e233  
rgb(112, 64, 226, 40%) #7040e24C  
rgb(112, 64, 226, 60%) #7040e299  
rgb(112, 64, 226, 80%) #7040e2CC  
rgb(112, 64, 226, 100%) #7040e2FF  

Saturated and desaturated colors of #7040e2

HSL Code Preview
hsl(258, 10%, 57%)  
hsl(258, 20%, 57%)  
hsl(258, 40%, 57%)  
hsl(258, 60%, 57%)  
hsl(258, 80%, 57%)  
hsl(258, 100%, 57%)  

#7040e2 Color Usage In CSS

 body {
    color: #7040e2;
    }
 p {
    color: rgb(112, 64, 226);
    }
 header {
    border-bottom:1px solid #7040e2;
    }
Recent Random Colors