Home

HTML - Web Page Structure


Basic HTML Code Structure

Given below is an example of a simple html code. You can cut-n-paste the below example and save as an .html file and view it in a web browser.

<html lang="en">
<head>
  <title>Hello World</title>
</head>
<body>
    Hello World!!!!
</body>
</html>

This is how it will appear in a web browser

hello world

Head and Title Tag

Head tag contains information about the web page. It usually contains nested tags like title and meta tags. These nested tags are used by web browser and search engines to get more information about web page.

The title tag contains the web page's title. The title is typically displayed in the title bar at the top of the browser window.

Web page validation

To ensure that web pages created are compliant with HTML standards, a free online Markup Validation Service from w3c can be used. Simply goto http://validator.w3.org/ and submit the code for free validation. The service will provide details on level of compliance with HTML standards and also suggestions on how to fix the errors.