Services Work Learn About Contact
0/8
Lesson 2 of 8

Document Structure

Every HTML document follows a basic structure. Understanding this structure is essential before you start writing your own pages.

The <!DOCTYPE html> declaration tells the browser this is an HTML5 document. The <html> element is the root element that wraps everything.

Inside <html>, there are two main sections: <head> (metadata, title, links to CSS) and <body> (the visible content).

HTML
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8">
    <title>Page Title</title>
  </head>
  <body>
    <!-- Visible content goes here -->
  </body>
</html>
🧠

Quick Quiz

Answer correctly to unlock the next lesson.

Support the mission

This learning platform is 100% free: no ads, no tracking, no paywalls. If it helped you learn something useful, you can support future lessons or donate to Doctors Without Borders, which provides emergency medical care in crisis zones worldwide.

🎉

You completed HTML!

You finished all 8 lessons and quizzes. You now know the basics of HTML.