The HTML <span> tag is used for grouping and applying styles to inline elements. span applies no meaning and is commonly used solely to apply CSS.

Required Attributes

  • None.

Optional Attributes

Example

<p>You could apply styles to <span class="whatever">this text</span> or <span class="whatever">tis thext</span> using the span tag. </p>

Changes in HTML5

  • None.

Related Tags