1. About.com
  2. Computing & Technology
  3. Web Design / HTML

Discuss in my forum

How To Change the Font Color with CSS

By , About.com Guide

It's easy to change the font color with one simple CSS style property.

In this article, you'll learn how to change the font color on a paragraph tag. But you can use the same style property to change the font color on any tag that surrounds text, including the <body> tag.

Difficulty: Easy
Time Required: 2 minutes
Here's How:
  1. Add the style attribute to the tag:

    <p style="">
  2. Place the color style property in the attribute value:

    <p style="color:">
  3. Then add your color to the style:

    <p style="color:red;">
  4. Type your text inside the paragraph.

  5. Close the paragraph tag:

    </p>
  6. The final HTML reads:

    <p style="color:red;">This text is red.</p>

©2012 About.com. All rights reserved. 

A part of The New York Times Company.