Lecture

Tags

In HTML, a Tag is the fundamental unit used to structure and present content on web pages.

A tag is composed of keywords enclosed in angle brackets (< >) like <tag>.

A tag consists of a start tag (<tag>) and an end tag (</tag>), with the content that the tag applies to placed in between.

Here is an example of the structure of an HTML tag.

HTML Tag Structure
<tag>Content that the tag applies to</tag>

The start tag is represented as <tagname> (e.g., <html>), while the end tag is represented as </tagname> (e.g., </html>) with a slash (/) in front of the tag name.

HTML Tag Example
<html> Hello World! </html>

Note: Some tags have a slash (/) placed after the tag name, known as a Self-closing Tag. We will learn more about self-closing tags in later lessons.


Practice

Follow the highlighted parts of the code to practice your input.

Mission
0 / 1

Which of the following is the most appropriate closing tag?

<tag>Content to which the tag is applied
<tag/>
</tag>
<tag>
</tag/>

Lecture

AI Tutor

Publish

Design

Upload

Notes

Favorites

Help