Let's build the smallest useful HTML page and read it from top to bottom, piece by piece.
- Start with <!DOCTYPE html>. This tells the browser that the document uses modern HTML. - Next, open <html lang="en">. This is the outer container for the whole page. - Inside <html>, open <head>. Think of <head> as the page's backstage information. - Add <meta charset="UTF-8"> so normal letters, symbols, emojis, and many world languages can be displayed correctly. - Add <title>My First Page</title>. This text belongs to the browser tab, not the visible page. - Close </head> before opening <body>. - Put the content visitors should see inside <body>. - Add <h1>Hello World!</h1> for the main heading. - Add <p>My first HTML page.</p> for a normal paragraph. - Close </body>, then close </html>. Notice the closing order: the last thing opened is the first thing closed.
The main lesson is that HTML gives the browser a clear structure. Each tag has a job, and nested tags show which pieces belong together.
