Lesson 2
•
20 min
Free
HTML Fundamentals
Structure your first web page with HTML.
HTML Fundamentals 📝
HTML (HyperText Markup Language) is the foundation of every webpage. Let's learn the basics!
Your First HTML
Every HTML document has this basic structure:
index.html
<!DOCTYPE html>
<html>
<head>
<title>My First Page</title>
</head>
<body>
<h1>Hello, World!</h1>
<p>This is my first webpage.</p>
</body>
</html>
Common HTML Tags
| Tag | Purpose | Example |
|---|---|---|
| <h1>-<h6> | Headings | <h1>Title</h1> |
| <p> | Paragraph | <p>Text here</p> |
| <a> | Link | <a href="url">Click</a> |
| <img> | Image | <img src="pic.jpg"> |
| <div> | Container | <div>Content</div> |
Try It Yourself!
💡 Exercise: Create a file called index.html and add:
- A heading with your name
- A paragraph about yourself
- A link to your favorite website
📚 Next Up
In the next lesson, we'll build a complete webpage from scratch!