X
HOME HTML CSS JAVASCRIPT SQL PHP JQUERY ANGULAR XML ASP.NET MORE...
REFERENCES | EXAMPLES | FORUM | ABOUT

HTML <font> Tag. Not Supported in HTML5.


Example

Specify the font size, font face and color of text:

<font size="3" color="red">This is some text!</font>
<font size="2" color="blue">This is some text!</font>
<font face="verdana" color="green">This is some text!</font>

Try it Yourself »

Definition and Usage

The <font> tag is not supported in HTML5. Use CSS instead.

The <font> tag specifies the font face, font size, and color of text.


Browser Support

Element
<font> Yes Yes Yes Yes Yes


Differences Between HTML 4.01 and HTML5

The <font> tag is not supported in HTML5.


Compatibility Notes

CSS Example: Set the color of text

CSS Example: Set the font of text

CSS Example: Set the size of text

In our CSS tutorial you can find more information about CSS text color and CSS fonts.


Optional Attributes

Attribute Value Description
color rgb(x,x,x)
#xxxxxx
colorname
Not supported in HTML5.
Specifies the color of text
face font_family Not supported in HTML5.
Specifies the font of text
size number Not supported in HTML5.
Specifies the size of text



Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]
Search w3schools.com:

WEB HOSTING

UK Reseller Hosting

WEB BUILDING

Download XML Editor FREE Website BUILDER Free HTML5 Templates FREE Website Templates Free HTML Templates

SHARE THIS PAGE

facebook