⏱️ Duration: 15 minutes | This section covers the absolute basics of web development.
What is a Website?
Every website you visit—from Netflix to TikTok to your university portal—is built with just three technologies: Think of a website like a human body:| Technology | What it does | Human analogy |
|---|---|---|
| 🦴 HTML | Structure & content | Skeleton + organs |
| 🎨 CSS | Appearance & style | Skin, hair, clothes |
| 🧠 JavaScript | Behavior & logic | Brain + muscles |
🤯 Did you know? The first website ever created is still online! Visit info.cern.ch—it was made in 1991 by Tim Berners-Lee. No CSS, no JavaScript, just pure HTML!
HTML: The Structure
HTML (HyperText Markup Language) defines the content and structure of web pages.Your First HTML Page
Common HTML Elements
| Element | Purpose | Example |
|---|---|---|
<h1> to <h6> | Headings | <h1>Title</h1> |
<p> | Paragraph | <p>Some text</p> |
<a> | Link | <a href="url">Click me</a> |
<img> | Image | <img src="photo.jpg" alt="Description"> |
<div> | Container | <div>Group of elements</div> |
<button> | Button | <button>Click</button> |
CSS: The Style
CSS (Cascading Style Sheets) controls how HTML elements look.Adding Styles
CSS Selectors
The Box Model
Every HTML element is a box with 4 layers. Think of it like a package:
| Layer | What it is | CSS Example |
|---|---|---|
| 📝 Content | Your text, images, etc. | width: 200px |
| 🧸 Padding | Space inside the border | padding: 20px |
| 🖼️ Border | The visible edge | border: 2px solid black |
| 📦 Margin | Space outside the border | margin: 10px |
- 📝 Content = The gift inside the box
- 🧸 Padding = Bubble wrap protecting the gift
- 🖼️ Border = The cardboard box itself
- 📦 Margin = Space between boxes on the shelf
JavaScript: The Behavior
JavaScript makes websites interactive.Your First Script
JavaScript Basics
DOM Manipulation
JavaScript can change HTML elements:Putting It All Together
Key Takeaways
HTML = Structure
Defines what content appears on the page
CSS = Style
Controls how content looks
JS = Behavior
Makes content interactive
Learn More
HTML Tutorial
W3Schools HTML Guide
CSS Tutorial
W3Schools CSS Guide
JavaScript Tutorial
W3Schools JS Guide
Next up: Tailwind CSS →