HTML » Tags » basefont

Version: 3.2

Compability: Explorer 4, 5  Netscape 4

<basefont> ... </basefont>

The element is deprecated in HTML 4.01.

The <basefont> tag is used to set the font appearance. The basefont tag is officially deprecated effective with HTML 4.0. It has been superseded by style sheets.

If placed between the head tags, the font values are set for the entire document. This tag can also be placed anywhere inside the body of the document where it can be used to set the font values for a local block of text. Under these circumstances, the basefont tag in the head is overridden.
The closing tag is optional. When the closing tag is used, it causes the font size to revert to the default value of 3.


<basefont size="3">

These two lines of code are equivalent.

Language(s): HTML
<basefont color="red" face="arial" size="7">DevGuru</basefont> is the best!
DevGuru is the best!

In this example, only the word DevGuru is affected by the tag. Beware that the color and face attributes are not recognized by some browsers.

Language(s): HTML

See Also: