HTML <html> Tag

The <html> element is used to give information to the browsers that it is an HTML document. This element represents the root of an HTML document.

The <html> element is the first HTML element in an HTML document (however, it must be preceded by a <!DOCTYPE>).

Any other HTML elements are placed inside the <html> element.

The first tag inside a <html> element must be a <head> tag, followed by a <body> tag.


The <html> element comes in pairs. The content must be written between opening (<html>) and closing (</html>) elements.


<!DOCTYPE html>
      <title>We place here document title.</title>
     <p>This is a paragraph for example.</p>


These attributes came along with HTML5.

Attribute Value Description
manifest URL Defines document's cache manifest's address for offline browsing.
xmlns Defines the ML namespace attribute.

The <html> element also supports the Global Attributes.