The structure of a document is very important because it is the main base of any webpage. Whatever programming language, web designing, or other field you choose, you should know the basic structure of the document.
If you want to create a webpage, you must use this structure first. Only then can you create a simple webpage. After that, you can do things like CSS, styling, and web design.
Basic HTML Structure
<!DOCTYPE html>
<html>
<head>
<title>Basic structure of a webpage</title>
</head>
<body>
<h1>Welcome to www.edutation.com</h1>
<p> You will know how to start the webpage.</p>
</body>
</html>
The following are the essential tag parts of the HTML document structure:
-
<!DOCTYPE html>
It specifies the HTML version you are using and tells the browser that this is an HTML5 document. -
<html> tag
It is the main or root tag of an HTML page; all other tags, such as <head> and <body>, are nested within it. -
<head> section
If you mention any information about your webpage inside this tag, the browser will not display it after execution. -
<title> tag
You will mention the title of your webpage inside this tag. -
<body> section
It is the essential part of a webpage structure that helps the browser read and display webpage content.
