Essential HTML Tags and Their Features: A Comprehensive Guide for Beginners

In this article I will discuss with you the essential html tags and its features. Learn it carefully and you have to practice it. In the final term question paper there are several questions on HTML.

First of all you have to know about tags. Tags in html start with <>(angle brackets) and close with </>(closing angle brackets).

But closing tags are not necessary for all cases. There are some tags which are called empty tag. 

empty tags have neither opening or closing tags. 

This is explained to you very easily with an example below:

WhatsApp Group Join Now
Telegram Group Join Now

On above example you can observe <br> tag which has no closing.

But <br> tag performing very effectively. This tag is used for line break. When you want to change the line then you put <br> tag at that location and line will be changed. The cursor has moved down to the places where the <br> tag was used and started writing the tests on the next line.

<h1></h1> tag is used for heading. It is a container tag, because it has both opening and closing.

Difference between empty and container tag:

Empty TagContainer Tag
Does not require a closing tag.Requires both an opening and closing tag.
Cannot enclose content.Can enclose content (text, other tags, etc.).
Self-closing or standalone.Consists of an opening tag and a closing tag.
Used for standalone purposes, such asadding line breaks or images.Used to group and structure content in a document.

1)Use of BOLD,ITALIC andUNDERLINE tags:

In HTML we use <b> tag to create a text bold.The syntax is:-

<b> india</b>

output:  india

<u> tag is used for underline a text.

Syntax: <u>india</u>

Output:  india

<i> tag is used for to give a text italic effect.

Syntax: <i>india</i>

Output:  india

If you want to use these all tags together then the syntax will be:

<b><i><u>India is my country</u></i></b>

Output: India is my country

HTML tags are not case sensitive, meaning you can write the tags in both capital and small case or(Uppercase or Lowercase).

This is explained to you very easily with the help of the following example.

<B><I><U>India is my country</B></I></U>

Output: India is my country

2) Heading tag:

In HTML there are 6 types of heading tags. <H1>,<H2>,<H3>,<H4>,<H5>,<H6>

<H1>—>This tag is the largest heading tag.

<H2>—>This tag is the smallest Heading tag.

This is explained below with an example using HTML script.

Generally in web pages <H1> tag is used for Heading and <H2> to <H6> tags are used for sub-headings.

3)Paragraph tag:

In html if you write 2 or more paragraphs then you should use <p> tag. 

<p> tag is the separator between two paragraphs.

Look carefully at the example below:

In the above diagram there are two paragraphs and they are separated by <p></p> tags.I hope you understand the use of the<p> tag.

4) Use of <br> tag:

Earlier when we discussed empty tags and container tags, we talked about <br> tags. This tag is used for changing lines. It is an empty tag.

5)Superscript and Subscript :

Superscript or <sup> tag is used to write a character above the line and subscript or <sub> tag is used to place a character below the line. This type of tag is generally used for mathematical expression.

6)Font tag:

Use of font tag is to create a text according to user choice or decorative text.  

By using font tag we can change text color, text font style and size of text.

Attributes of the <font> Tag

  1. face: Specifies the font family of the text (e.g., Arial, Verdana).

Example: face=”Arial”

  1. size: Defines the size of the text.

 Example: size=”4″

  1. color: Sets the color of the text, either using color names, hex codes, or RGB values.

Example: color=”blue” or color=”#FF5733″

 7.<BODY> tag:

According to your syllabus there are 2 attributes of body tags available in your book.

<BODY BGCOLOR=”yellow” >

If the above code is executed then the background colour of the entire webpage will be yellow.

You can also use the hex code of the color which is available on google.

EX-#ff0000

<BODY ALIGN=”CENTER”>

<BODY ALIGN=”LEFT”>

<BODY ALIGN=”RIGHT”>

<BODY ALIGN=”JUSTIFY”>

Above codes are used to align the text at the particular position.

8.Heading tag:

The <head> tag includes meta-information about the webpage, such as its title, description, keywords, author, and more. This information is often used by search engines, browsers, and other tools.

Download pdf file for MCQ

Leave a Comment