View video tutorial

HTML <sup> Tag

HTML

The <sup> tag defines superscript text.

HTML <sup> Tag


The Superscripts text displays half a character above the normal line.

Superscripts are usually rendered with the upper baseline using smaller text.

Superscripts are widely used in mathematics or similar fields.

Global attributes

Global attributes may be applied on all elements, although some elements may have no effect on them.

<accesskey>, <class>, <contenteditable>, <contextmenu>, <data-*>, <dir>, <draggable>, <dropzone>, <hidden>, <id>, <lang>, <spellcheck>, <style>, <tabindex>, <title>, <translate>.

Learning with HTML Editor "Try it Now"

You can edit the HTML code and view the result using online editor.

Example

<p>This is an example of <sup>superscript</sup> text.</p>
<p>Example: (a+b)<sup>2</sup> = a<sup>2</sup> + 2ab + b<sup>2</sup>.</p>
Try it Now »

Click on the "Try it Now" button to see how it works.