Horje
What is HTML HEX Colors

A hexadecimal color is specified with: #RRGGBB, where the RR (red), GG (green) and BB (blue) hexadecimal integers specify the components of the color.

Text color using Hex color codes

The most common way of coloring HTML text is by using hexadecimal color codes (Hex code for short). Simply add a style attribute to the text element you want to color – a paragraph in the example below – and use the color property with your Hex code.


Text color using Hex color codes

The most common way of coloring HTML text is by using hexadecimal color codes (Hex code for short). Simply add a style attribute to the text element you want to color – a paragraph in the example below – and use the color property with your Hex code.
index.html
Example: HTML
<!DOCTYPE html>
<html>
<body>
  <p style="color:#FF0000";>Red paragraph text</p>
</body>
</html>

Output should be:

Text color using Hex color codes

Text color using HTML color names

Another way to color your website's text is by using an HTML color name. The HTML code is similar, just replace the Hex code from the previous step with the name of the color you want to use (red in our example). There are 140 named colors to choose from, and we've compiled a list which you can check out here.
index.html
Example: HTML
<!DOCTYPE html>
<html>
<body>
  <p style="color:red;">Red paragraph text</p>
</body>
</html>

Output should be:

Text color using HTML color names
Reffered: https://htmlcolorcodes.com/tutorials/html-text-color/





Related Articles
What is HTML HEX Colors HTML HEX Colors
How to create HTML HEX Color Values HTML HEX Colors
How to create HTML Shades of Gray HTML HEX Colors

Single Articles
Text color using Hex color codesHTML HEX Colors
Text color using HTML color namesHTML HEX Colors

Read Full:
HTML HEX Colors
Category:
Web Tutorial
Sub Category:
HTML HEX Colors
Uploaded:
1 year ago
Uploaded by:
Admin
Views:
55



Share on: