HTML Color Examples


Example Code




<!-- Codes by HTMLmagics -->
<p style="color:blue;">Text color defined using the color name.</p>
<p style="color:#0000ff;">Text color defined using its hexadecimal value.</p>
<p style="color:#00f;">Text color defined using its shorthand hexadecimal value.</p>
<p style="color:rgb(0,0,255);">Text color defined using the RGB color value.</p>
<p style="color:rgb(0%,0%,100%);">Text color defined using the RGB color percentage value.</p>
<p><a  style="font-size:11px;color:#999;" href="http://www.htmlmagics.blogspot.com/color/html-color-codes.cfm">HTML color codes</a></p>


Result





Text color defined using the color name.
Text color defined using its hexadecimal value.
Text color defined using its shorthand hexadecimal value.
Text color defined using the RGB color value.
Text color defined using the RGB color percentage value.