<sub> tag

HTML <sub> tag

The <sub> tag is used to show subscript.

Normally, you should use this for showing scientific and mathematical formulas.

The text inside this element appears at the bottom of its normal position from the baseline.

And, this will appear almost half of its original size in the browser.

Syntax:
<sub>text…</sub>

Example

<p>H<sub>2</sub>O Water</p>

How Browser will display

INLINE.

Difference between HTML4.01, XHTML and HTML5

HTML4 XHTML HTML5
None None None

Attributes used with <sub> tag

NONE

Global Attributes

The <sub> tag supports Global attributes.

Event Attributes

The <sub> tag supports Event attributes.

Supporting Browsers

supporting-browsers for tags

Related Tags

<sup> tag.

Tutorials for all brains!