HTML Tags

Every Thing in HTML is written in tags or html tags. HTML5 includes around 140+ tags. These tags are used to build webpage structure, like p, h1, h2, h3, address, b, i, etc. Tags can have Attributes.

Here is an pictorial view of HTML Tag.

HTML Tags
HTML tags

Type of HTML Tags

Based on opening and closing, tags are categorized as Pair Tags and Non Pairs Tags.

Tag Type Use
Pair Tag

Pair Tags are written in pairs, means separate opening and closing tag.
Exp html, body, head, h1, p, div etc.

Non pair Tags

Non pair or self closing tags. They don't need closing, as they are self closed. Some Non Pair tags are <img >, <meta > <input > <link >, <br >, <hr >

Non pair elements don't have any child or children. They are last node of HTML DOM Tree.


HTML Tag List

HTML5 includes around 142 tags. Some Tags are removed in html5, and some new tags are added in html5. Some tags are renamed in html5. Here is a complete list of HTML5 Tags with name, use and version in which they were introduced.

Red marked rows are HTML5 Tags.

List of html tags

HTML Tags List
S NoTag NameUseversion
1 a Hyperlink, earlier anchor tag 4
2 abbr abbreviation 4
3 address To add postal information 4
4 area Hyperlink for Image Map 4
5 article An independentent article. 5
6 aside side bar for layout 5
7 audio To play audio file 5
8 b bold tag 4
9 base base URL 4
10 bdi BiDi Isolate 5
11 bdo BiDi Override 4
12 blockquote Block level quotation 4
13 body body of web document 4
14 br line break 4
15 button button tag 4
16 button type="button" button tag 4
17 button type="reset" reset button for form 4
18 button type="submit" submit button for form 4
19 canvas canvas tag for drawing, graphics and games 5
20 caption caption for table tag 4
21 cite cited title 4
22 code Code to show 4
23 col column for table 4
24 colgroup group for table columns 4
25 command command 5
26 command type="command" command for an action 5
27 command type="radio" select single item from list 5
28 command type="checkbox" check or uncheck items from list 5
29 datalist datalist for input controls 5
30 dd description data 4
31 del deleted text 4
32 details details for collapsible content 5
33 dfn Define Instance 4
34 div division, block level element for grouping 4
35 dl Description List 4
36 dt Description Term 4
37 em emphasize text 4
38 embed To embed plugins 4
39 fieldset group of form controls 4
40 figcaption caption for figure 4
41 figure Items like picture or graphical content 5
42 footer footer of content 5
43 form form to submit user information to server 4
44 h1 Heading level 1 4
45 h2 Heading level 2 4
46 h3 Heading level 3 4
47 h4 Heading level 4 4
48 h5 Heading level 5 4
49 h6 Heading level 6 4
50 head head tag 4
51 header header for article, or section 5
52 hgroup group for headings 5
53 hr thematic break, earlier known as horizontal break 4
54 html root 4
55 i italic text 4
56 iframe inline frame for extarnal webpages or plugins 4
57 img image 4
58 input input control 4
59 input type="text" input control for text field 4
60 input type="password" input control for password 4
61 input type="checkbox" input control for checkbox 4
62 input type="radio" input control for radio 4
63 input type="button" input control for button 4
64 input type="submit" submit button 4
65 input type="reset" reset button 4
66 input type="file" file upload control 4
67 input type="hidden" input control hidden 4
68 input type="image" input image 4
69 input type="datetime" input control for global date and time 5
70 input type="datetime-local" input control for local date and time 5
71 input type="date" input control for date 5
72 input type="month" input control for month 5
73 input type="time" input control for time 5
74 input type="week" input control for week and year 5
75 input type="number" input control for numbers 5
76 input type="range" input control for range 5
77 input type="email" input control for email id 5
78 input type="url" input control for URL 5
79 input type="search" input control for search field 5
80 input type="tel" input control for datetime 5
81 input type="color" input control for datetime 5
82 ins insert text 4
83 kbd keyboard command 4
84 keygen key/pair generator input control 4
85 label caption for input and form controls 4
86 legend title for fieldset 4
87 li list item 4
88 link link for css, icon, canonical etc. 4
89 map image map 4
90 mark marked or highlighted text 5
91 menu list of commands 4
92 meta metadata 4
93 meta name metadata for key-value, exp description, keywords etc 4
94 meta http-equiv="refresh" metadata to refresh page 4
95 meta http-equiv="default-style" metadata for preffered stylesheet 4
96 meta charset metadata for charset encoding declaration, exp utf-8 5
97 meta http-equiv="content-type" metadata for charset encoding 4
98 meter meter , a scalar gauge 5
99 nav group of navigation links 5
100 noscript fallback conent if javascript is disabled in browser 4
101 object genetic external object 4
102 ol ordered list 4
103 optgroup group of options 4
104 option option for select and datalist 4
105 output result of calculations 5
106 p paragraph 4
107 param initilization parameter for plugins 4
108 pre preformatted text 4
109 progress progress indicator 5
110 q inline quoteted text 4
111 rt ruby parenthesis 5
112 rt ruby text 5
113 ruby ruby annotation 5
114 s struck text 4
115 samp sample output 4
116 script internal or external javascript 4
117 section container 5
118 select select dropdown 4
119 small small print 4
120 source media source for audio, video and picture 5
121 span inline level grouping 4
122 strong strong importance 4
123 style internal or embedded stylesheet 4
124 sub subscript 4
125 summary caption for details element 5
126 sup superscript 4
127 table table element 4
128 tbody table row group 4
129 td table data or cell 4
130 textarea input textarea 4
131 tfoot table footer row group 4
132 th table header cell 4
133 thead table heading group 4
134 time date or time 5
135 title title for web document 4
136 tr table row 4
137 track media track 5
138 u underline text 4
139 ul 4
140 var variable text 4
141 video video 5
142 wbr possible line break 5


HEAD Tag

HTML Head tag is the first child of HTML Element.
It Contains all information related to webpage, css links, scripts and meta tags.

  • Title Tag
  • Meta Tags
  • Link Tags
  • Script Tags

<!DOCTYPE html>
<head>
	<title> Title of the webpage </title>
		<meta charset="utf-8" >
		<meta name="keywords" content="Keywords of your website" >
		<meta name="description" content="Search Description of your website" >
		<link href="style.css" rel="stylesheet" >
<script >
  script Goes Here
<script/>
</head>
		
		

BODY Tag

HTML Body Tag is used to define the body of our HTML Document
The Body Tag contains all visible contents of a web page like paragraph, headings, tables, lists, images, videos etc.
By Default, body is 100% wide and takes a margin of 8px.


<body> 
	Complete Website Structure will be created inside
 </body>
		
		

HTML TITLE

Title is the first child of HEAD Tag. Title tag is must be unique on every webpage of a website.
It enhance search visibility of a webpage on search engines.
Maximum limits of characters inside title tag is 70.


<title> Title of the webpage </title>