Superscript and subscript present information in certain ways that make it more easily understandable and are useful for communicating some specific types of information. A superscript is text that is higher and often smaller than the main text. It is used for suffixes of dates (such as in 21st June) and in mathematics for representing the power to which a number is raised (such as in 210). A subscript, in contrast, is text that is lower and also often smaller than the main text. It is used in a number of different representations, such as chemical formulas (such as in CO2), mathematical expressions (such as in logio), and footnotes. The HTML elements used to create them are <sup> and <sub>, respectively. Figure 3.12 shows how they are used, and Figure 3.13 depicts the result.
Source: Sklar David (2016), HTML: A Gentle Introduction to the Web’s Most Popular Language, O’Reilly Media; 1st edition.