HTML - Span element

1 - About

The span element is a generic wrapper for phrasing content that by itself does not represent anything.

Span doesn't have explicit attributes.

3 - Usage

Span is then handy to use:

4 - Rendering

div elements are rendered as block boxes whereas span element are rendered as inline box.


  • The world word will then stay on the same line (ie in the p block element.

Hallo <span style="color:green">World</span>

  • Output:

5 - Documentation / Reference

Data Science
Data Analysis
Data Science
Linear Algebra Mathematics

Powered by ComboStrap