Menu
Coddy logo textTech

Tags and Elements

Part of the Fundamentals section of Coddy's HTML journey — lesson 3 of 60.

In HTML, tags are keywords enclosed in angle brackets, like <html>. They tell the browser how to display the content. Elements are the components of an HTML document, consisting of a start tag, content, and an end tag.

Here's a simple breakdown:

  • Tags: Keywords in angle brackets that define how content is displayed.
  • Elements: Components made up of a start tag, content, and an end tag.

For example:

<p>This is a paragraph.</p>

In this example, <p> is the start tag, "This is a paragraph." is the content, and </p> is the end tag. Together, they form a paragraph element.

challenge icon

Challenge

Easy

You are given an HTML code with a paragraph tag (<p>) change the text inside the paragraph to:

Hello, HTML!

Make sure to not delete the start or end tag!

Cheat sheet

HTML tags are keywords enclosed in angle brackets that tell the browser how to display content. Elements consist of a start tag, content, and an end tag.

Example of a paragraph element:

<p>This is a paragraph.</p>

Structure breakdown:

  • <p> - start tag
  • "This is a paragraph." - content
  • </p> - end tag

Try it yourself

<!DOCTYPE html>
<html>
    <body>
        <p>This is some text</p>
    </body>
</html>
quiz iconTest yourself

This lesson includes a short quiz. Start the lesson to answer it and track your progress.

All lessons in Fundamentals