š§± HTML Basics ā A Beginnerās Guide to Web Structure
HTML (HyperText Markup Language) is the foundation of every webpage. It defines the structure and content ā like text, images, links, and forms ā in a browser-readable format.
š¦ Basic Structure of an HTML Document
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>My First HTML Page</title>
</head>
<body>
<h1>Hello, World!</h1>
<p>This is my first web page.</p>
</body>
</html>
| Tag | Purpose |
|---|---|
<!DOCTYPE> | Declares HTML5 version |
<html> | Root of the HTML document |
<head> | Metadata (title, styles, etc.) |
<body> | Visible content of the page |
š Common HTML Tags
š Text Tags
<h1> to <h6> <!-- Headings -->
<p> <!-- Paragraph -->
<strong> <!-- Bold -->
<em> <!-- Italic -->
<br> <!-- Line break -->
<hr> <!-- Horizontal line -->
š Links and Images
<a href="https://example.com">Visit Site</a>
<img src=“logo.png” alt=“Logo” width=“200” />
š Lists
<ul> <!-- Unordered list -->
<li>Item 1</li>
<li>Item 2</li>
</ul>
<ol> <!– Ordered list –>
<li>Step 1</li>
<li>Step 2</li>
</ol>
š¦ Containers and Layout
<div>Generic container</div>
<span>Inline container</span>
š§¾ Tables
<table>
<tr>
<th>Name</th><th>Age</th>
</tr>
<tr>
<td>Anil</td><td>28</td>
</tr>
</table>
š¤ Forms (Basic)
<form action="/submit" method="POST">
<label for="name">Name:</label>
<input type="text" id="name" name="name" required />
<button type="submit">Submit</button>
</form>
ā Semantic HTML (Better Structure)
Use these tags to give meaning to your layout:
<header> <!-- Page or section header -->
<nav> <!-- Navigation links -->
<main> <!-- Main content -->
<article> <!-- Blog post or similar -->
<section> <!-- Thematic grouping -->
<footer> <!-- Page footer -->
š§ HTML Attributes
Attributes provide extra information about an element:
<a href="https://example.com" target="_blank" title="Visit">Visit</a>
| Attribute | Description |
|---|---|
href | Link target |
src | Image source |
alt | Image description |
id / class | Used for styling or scripting |
type / value / name | Used in forms |
š Tips for Beginners
Always use proper nesting (tags inside tags)
Close all your tags (except self-closing like
<br>or<img>)Use
alttext for images (for accessibility)Validate your HTML: https://validator.w3.org
ā 1. š Interactive HTML Practice (Beginner-Friendly)
Use this platform to code and preview instantly:
š Start with this code snippet:
<!DOCTYPE html>
<html>
<head>
<title>My Practice Page</title>
</head>
<body>
<h1>Hello!</h1>
<p>This is my first HTML practice.</p>
<a href="https://www.google.com" target="_blank">Visit Google</a>
</body>
</html>
ā 2. š§¾ Downloadable PDF Cheat Sheet
Would you like a PDF version of the HTML Basics Cheat Sheet (with tags, syntax, structure)?
š½ I can generate a print-ready PDF for you.
š Just reply:
āSend the HTML cheat sheet PDFā ā and Iāll provide it right here.
ā 3. š Starter Project: HTML + CSS + JS
I can give you a simple mini project like:
š Personal Profile Page
š° Simple Blog Layout
š Todo List (with JS)
š¼ļø Image Gallery
š Just tell me what you’d like (e.g., āI want the blog layoutā), and Iāll create a clean, ready-to-edit template for you.
ā 1. HTML Basics Cheat Sheet (PDF)
š§¾ A neatly formatted PDF covering:
Page structure
Common tags (text, images, links, forms, etc.)
Semantic HTML
Example snippets
Attribute reference
Best practices
š§ Generating your downloadable PDF…
(Iāll share it in the next message.)
ā 2. Starter Project (Choose One)
Pick one and Iāll send you the complete HTML + CSS + JS template:
š§ Personal Profile Page
š° Simple Blog Layout
š Todo List (with JavaScript)
š¼ļø Image Gallery
šØ Portfolio Website
š¬ Contact Form Page

































































































