Semantic HTML Cheat Sheet
Semantic HTML Cheat Sheet
There are hundreds of semantic tags available to help describe the meaning of your HTML documents.
Below is a cheat sheet with some of the most common ones you’ll use in this course and in your
development career.
Sectioning tags
Use the following tags to organize your HTML document into structured sections.
<header>
The header of a content section or the web page. The web page header often contains the website
branding or logo.
<nav>
<footer>
The footer of a content section or the web page. On a web page, it often contains secondary links, the
copyright notice, privacy policy and cookie policy links.
<main>
<aside>
A secondary set of content that is not required to understand the main content.
<article>
<section>
A standalone section of the document that is often used within the body and article elements.
<details>
A collapsed section of content that can be expanded if the user wishes to view it.
<summary>
<h1><h2><h3><h4><h5><h6>
Headings on the web page. <h1> indicates the most important heading whereas <h6> indicates the least
important.
Content tags
<blockquote>
<dd>
<dl>
<dt>
<figcaption>
<figure>
<li>
<menu>
<ol>
<p>
Defines a paragraph.
<pre>
Used to represent preformatted text. Typically rendered in the web browser using a monospace font.
<ul>
Unordered list
Inline tags
<a>
<abbr>
Bolds the containing text. When used to indicate importance use <strong> instead.
<br>
<cite>
Defines the title of creative work (for example a book, poem, song, movie, painting or sculpture). The
text in the <cite> element is usually rendered in italics.
<code>
<data>
<em>
<i>
The containing text is displayed in italics. Used to indicate idiomatic text or technical terms.
<mark>
<q>
<s>
Displays the containing text with a strikethrough or line through it.
<samp>
<small>
<span>
<strong>
<sub>
<sup>
<time>
<u>
<var>
<audio>
<canvas>
<embed>
Used as a containing element for external content provided by an external application such as a media
player or plug-in application.
<iframe>
<img>
<object>
<picture>
An element that contains one <img> element and one or more <source> elements to offer alternative
images for different displays/devices.
<video>
<source>
Table tags
<table>
<thead>
Represents the header content of a table. Typically contains one <tr> element.
<tbody>
<tfoot>
Represents the footer content of a table. Typically contains one <tr> element.
<tr>
Represents a row in a table. Contains one or more <td> elements when used within <tbody> or <tfoot>.
When used within <thead>, contains one or more <th> elements.
<td>
<th>
Defines a header cell of a table. Contains the text content of the header.
<caption>
<col>