Structuring Your HTML

HTML defines three tags that are used to define the page’s overall structure and provide some simple header information . These three tags— <html> , <head> , and <body> —make up the basic skeleton of every web page. They also provide simple information about the page before loading the entire thing. The page structure tags don’t affect what the page looks like when it’s displayed; they’re only there to help browsers.

Screenshot from 2020-10-23 17-18-04

The <html> Tag
The first page structure tag in every HTML page is the <html> tag. It indicates that the content of this file is in the HTML language. The <html> tag should immediately follow the DOCTYPE identifier (as mentioned in the previous note), as shown in the following example.

All the text and HTML elements in your web page should be placed within the beginning and ending HTML tags, like this:
<!DOCTYPE html>
<html>
…your page…
</html>

The <head> Tag
The <head> tag is a container for the tags that contain information about the page, rather than information that will be displayed on the page. Generally, only a few tags are used in the <head> portion of the page. You should never put any of the text of your page into the header (between <head> tags). Here’s a typical example of how you properly use the <head> tag.

<!DOCTYPE html>
<html>
<head>
<title>This is the Title. It will be explained later on</title>
</head>
…your page…
</html >

The <body> Tag
The content of your HTML page resides within the <body> tag. This includes all the text and other content (links, pictures, and so on). In combination with the <html> and <head> tags, your page will look something like this:

<!DOCTYPE html><html>
<head>
<title>This is the Title. It will be explained later on</title>
</head>
<body>
…your page…
</body>
</html>