FSM Full Stack Masterclass
Platform under construction
HTML course badge

HTML Basics

Intermediate

HTML Elements

Explore the HTML element system and open dedicated lessons for headings, text, links, images, lists, forms, tables and layout.

HTML elements

Elements are the vocabulary of an HTML document.

Elements are the named building blocks of a page. A heading is not just large text, a list is not just lines under each other and a form is not just a few input boxes. Each element tells the browser what kind of content it is reading.

Use this page as the element map. Start with the document root, metadata and body, then move into landmarks, sections, headings, text, media, tables and forms. Each card opens a dedicated lesson with syntax, examples, common mistakes, accessibility notes, production context and a live code lab.

Learning rule: choose an element for meaning first. Styling belongs in CSS. Behavior belongs in JavaScript. HTML should make sense before either of them is added.
<p class="intro">Hello world</p>
Opening tag <p class="intro">

The element starts here. The browser now knows a paragraph begins.

Attribute class="intro"

The class is a styling or scripting hook. It does not change the meaning of the paragraph.

Content Hello world

This is the actual text content the paragraph contains.

Closing tag </p>

The paragraph ends here. Most text elements need a closing tag.

Complete element <p class="intro">Hello world</p>

The complete element is the opening tag, optional attributes, content and closing tag together.

1. Document shell

Learn html, head and body first. They decide where metadata ends and visible content begins.

2. Page structure

Use landmarks, sections and headings to create a page that can be scanned, indexed and navigated.

3. Real content

Text, lists, links, media, tables and forms become easier when the structure underneath is already clean.

Live code lab

Change the code and run the example.

Edit the HTML or CSS, then use Run to refresh the preview. The preview is isolated, so links and forms stay inside this practice area.

Mini assignment

Try this now.

  • Change the first paragraph into a short list with two items.
  • Add one new section with its own h2 heading.
  • Run the preview and check whether the page still makes sense without looking at the CSS.

Practice assignment

Do this before moving to the next lesson.

  1. Keep one h1 as the main subject of the page.
  2. Use two h2 elements for two clear sections.
  3. Write four paragraphs and check whether the HTML still reads well without CSS.

Try it yourself

Build a tiny semantic page

Live preview

Self-check

Before you continue, prove that you own this lesson.

Intermediate

Do not only read this page. Answer these questions out loud or write the answers in your own notes. If one answer feels vague, revisit the examples before moving on.

  1. Can you point out the opening tag, attributes, content and closing tag in a complete element?
  2. Can you explain why an element should be chosen for meaning before appearance?
  3. Can you name one case where a div is weaker than a semantic element?
  4. Can you identify which part of the page belongs in head and which belongs in body?
  5. Can you turn a loose group of content into a clear section with a heading?