
An HTML document is structured using a series of HTML elements, which are represented by tags. Here is a basic structure of an HTML document:
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<header>
<!-- header content -->
</header>
<nav>
<!-- navigation links -->
</nav>
<main>
<!-- main content of the page -->
</main>
<aside>
<!-- aside content -->
</aside>
<footer>
<!-- footer content -->
</footer>
</body>
</html>
DOCTYPE
The <!DOCTYPE html>
declaration is used to specify the version of HTML being used in the document.
HTML
The <html>
element is the root element of an HTML page and contains all the other elements.
Head
The <head>
element provides meta information about the document, such as the title of the page, which is displayed in the browser’s title bar or tab.
Body
The <body>
element contains the main content of the page, including the header, navigation, main content, aside, and footer sections.
Header
The <header>
element is typically used to contain the header content, such as the logo and site title.
Nav
The <nav>
element is used to contain navigation links.
Main
The <main>
element is used to contain the main content of the page, such as articles, images, and videos.
Aside
The <aside>
element is used to contain content that is related to the main content but can be considered separate, such as a sidebar.
Footer
The <footer>
element is used to contain the footer content, such as copyrights and links to other pages.