Computer >> Computer tutorials >  >> Programming >> HTML

Create superscripted text in HTML


Use the <sup> tag to create superscripted text. The HTML <sup> tag is used for defining subscript text like,

2<sup>3</sup> + 3<sup>2</sup> = 17

Example

You can try to run the following code to display subscripted text in HTML −

<!DOCTYPE html>
<html>
   <head>
      <title>HTML sup Tag</title>
   </head>
   <body>
      Value of 2<sup>3</sup> + 3<sup>2</sup> = 17
   </body>
</html>