What is HTML?
HTML (HyperText Markup Language) is the standard language used to create and design web pages. It structures the content on the web using elements like headings, paragraphs, links, images, and more.
Key Points:
- HTML stands for HyperText Markup Language.
- It is used to structure content on the web.
- HTML works with CSS (for styling) and JavaScript (for interactivity).
History and Evolution of HTML
HTML has evolved significantly since its creation in 1991 by Tim Berners-Lee.
Versions of HTML:
- HTML 1.0 (1993): The first version with basic text and links.
- HTML 2.0 (1995): Introduced form elements.
- HTML 3.2 (1997): Added support for tables, scripts, and CSS.
- HTML 4.01 (1999): Improved accessibility and multimedia support.
- XHTML (2000): A stricter, XML-based version of HTML.
- HTML5 (2014 – Present): Introduced semantic tags, audio, video, and APIs.
Why is HTML5 Important?
- Supports mobile-friendly design.
- Enables rich multimedia content without plugins.
- Provides better SEO and accessibility.
HTML vs. Other Markup Languages
HTML is a markup language, not a programming language. It differs from other languages in the following ways:
Feature | HTML | XML | Markdown |
---|---|---|---|
Purpose | Web structure | Data storage | Simple formatting |
Tags | Predefined | Customizable | Limited |
Usage | Webpages | Data exchange | Documentation, blogs |
Setting Up Your First HTML Page
To start coding in HTML, follow these steps:
Step 1: Create a Basic HTML File
Open a text editor (Notepad, VS Code, Sublime Text) and create a new file named index.html.
Step 2: Write the Basic HTML Structure
htmlCopyEdit<!DOCTYPE html>
<html>
<head>
<title>My First HTML Page</title>
</head>
<body>
<h1>Welcome to My Website</h1>
<p>This is my first webpage using HTML.</p>
</body>
</html>
Step 3: Save and Open in Browser
- Save the file as index.html.
- Open it in any web browser (Chrome, Firefox, Edge).
Conclusion
HTML is the foundation of web development. In this chapter, you learned:
✅ What HTML is and its importance.
✅ The evolution of HTML and the role of HTML5.
✅ How HTML compares to other markup languages.
✅ How to set up and run your first HTML page.