Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

How to define the document’s body in HTML5 ?

  • Last Updated : 12 Mar, 2021

The document’s body in HTML5 is defined by the <body> tag which is placed with in the <html> tags and just after the <head> tag.
The body tag can include:

  • headings tags : <h1>, <h2>, <h3> and so on.
  • paragraph tag: <p>
  • line break tag: <br>
  • horizontal rule tag: <hr>
  • image and video tags: <img> <video>
  • list tags: <ul> and <ol>
  • table tag: <table>

The body tag contains so many other tags, all the vital information on the web-page, or someone can say that it is the skeleton on the web-page.

Example: Below example illustrates the use of body tag.


<!DOCTYPE html>
<html lang="en">
  <!-- Paragraph Tag-->
  <!--H1 Tag--> 
  <!--H2 Tag-->
  <!--H3 Tag-->
  <!--H4 Tag-->
  <!--Line Break Tag-->
  <!--Horizontal Rule Tag-->
  <!--Image Tag-->
  <img src=
  <h2>Geeks-For-Geeks is Best Site For:</h2>
  <!--unordered list tag--->
    <li>Web Development</li>
    <li>and much more....</li>

Output: All the tags we have used inside our body tag is now visible on the web-page. The image gets down below shows the output of the above code and the use of each and every tag that we have used in our body tag.

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!