โ— HTML BASICS ยท CHAPTER 01

What is HTML?

HTML stands for HyperText Markup Language. It is the standard markup language used to create and structure the content of webpages. HTML tells the browser what each piece of content means โ€” such as a heading, paragraph, image, link, list, table, or form.

๐ŸŽฏ What you'll learn
  • What HTML means
  • Why HTML is needed
  • How a browser reads HTML
  • What HTML tags and elements are
  • How to create your first webpage
  • How HTML works with CSS and JavaScript

๐Ÿ’ก HTML in Simple Words

Think of a webpage as a building. HTML provides the structure of the building. It tells the browser where the headings, paragraphs, images, links, forms and other pieces of content belong.

๐Ÿ—๏ธ
HTMLStructure of the webpage
๐ŸŽจ
CSSAppearance and design
โš™๏ธ
JavaScriptBehavior and interaction
โ„น๏ธ
Important: HTML is a markup language, not a programming language. HTML describes the structure and meaning of content; it does not provide general programming logic like loops, conditions, or functions.

๐Ÿค” Why Do We Need HTML?

A browser needs a way to understand what each piece of content represents. For example, it needs to know which text is a heading, which text is a paragraph, which item is a link, and which item is an image.

Example
<h1>Welcome to ManaCoding</h1>
<p>Learn Java Full Stack Development.</p>
<a href="#">Start Learning</a>

The browser reads these elements and uses them to build and display the webpage.

๐Ÿง  How Does HTML Work?

01
Write HTMLYou create markup using HTML elements.
02
Browser ReadsThe browser parses the HTML document.
03
Browser Builds DOMThe markup is represented as a document tree.
04
Page AppearsThe browser renders the page for the user.

๐Ÿท๏ธ Common HTML Tags

HTML uses tags to describe different types of content.

<h1>HeadingDefines a main heading.
<p>ParagraphDefines a paragraph of text.
<a>LinkCreates a hyperlink to another resource.
<img>ImageEmbeds an image into the page.
<ul>Unordered ListCreates a bulleted list.
<form>FormGroups controls used to collect user input.

๐Ÿงฉ What is an HTML Element?

An HTML element is a complete piece of HTML. A common element contains an opening tag, content, and a closing tag.

HTML Element
<p>Hello World</p>
PartMeaning
<p>Opening tag
Hello WorldElement content
</p>Closing tag
๐Ÿ’ก
Some HTML elements are void elements and do not have a closing tag. Examples include <img>, <br>, and <input>.

๐Ÿš€ Create Your First HTML Page

index.html
<!DOCTYPE html>
<html>
<head>
    <title>My First Web Page</title>
</head>

<body>
    <h1>Hello World</h1>
    <p>This is my first webpage.</p>
</body>
</html>

๐Ÿ” Understand Each Part

CodeWhat it does
<!DOCTYPE html>Declares the document as HTML.
<html>The root element of the document.
<head>Contains document metadata and resources.
<title>Sets the title shown in the browser tab.
<body>Contains the page content displayed to the user.
<h1>Creates a main heading.
<p>Creates a paragraph.

โ–ถ๏ธ Try HTML Yourself

Don't just read the code. Change it, run it, and observe what happens.

๐Ÿ“ Interactive HTML Editor
Edit Code
Live Preview
๐ŸŽฏ
Challenge: Change the heading, add another paragraph, and create a list containing three skills.

๐ŸŒŽ Real-World Example

Imagine you are creating a student profile for ManaCoding. HTML can define the structure of that profile:

Student Profile
<h1>Jai Sai Ram</h1>
<p>Java Full Stack Developer</p>

<h2>Skills</h2>
<ul>
    <li>Java</li>
    <li>Spring Boot</li>
    <li>Angular</li>
</ul>

This is the key idea: HTML describes what the content is, not just how it should look.

โš ๏ธ Common Beginner Mistakes

  • Forgetting to close normal elements such as <p> and <h1>.
  • Incorrectly nesting elements.
  • Using HTML tags only because they look a certain way.
  • Forgetting useful attributes such as alt on images.
  • Confusing HTML structure with CSS styling.
Incorrect
<p><strong>Hello</p></strong>
Correct
<p><strong>Hello</strong></p>

๐Ÿงช Practice

๐ŸŸข BEGINNER

Personal Introduction

Create a page containing your name, city, education, and a short paragraph about yourself.

๐ŸŸก INTERMEDIATE

Student Profile

Create a profile containing a heading, image, paragraph, skills list, and contact link.

๐Ÿ”ด CHALLENGE

Course Card

Create a ManaCoding course page with course name, description, duration, skills, fee, and enrollment link.

๐Ÿ’ผ Interview Questions

Q1. What is HTML?

HTML stands for HyperText Markup Language. It is the standard markup language used to structure content on webpages.

Q2. Is HTML a programming language?

No. HTML is a markup language. It describes the structure and meaning of content, while programming languages provide logic such as conditions, loops, and functions.

Q3. What is an HTML element?

An HTML element is a complete piece of markup, commonly made up of an opening tag, content, and a closing tag.

Q4. What is the difference between HTML, CSS, and JavaScript?

HTML defines structure, CSS controls presentation, and JavaScript adds behavior and interactivity.

Q5. What does <!DOCTYPE html> do?

It tells the browser that the document is an HTML document and enables standards-based rendering.

๐Ÿ“ Quick Summary

Remember these five things:
  • HTML means HyperText Markup Language.
  • HTML provides the structure of a webpage.
  • HTML uses elements and tags to describe content.
  • CSS controls appearance and JavaScript controls behavior.
  • The best way to learn HTML is to write, run, change, and practice the code.

๐Ÿš€ What Should You Learn Next?

Now that you understand what HTML is, learn how HTML evolved and why modern HTML uses semantic elements.

โžก๏ธ
Next: Continue with the HTML Basics section.