HTML <html> Tag

Description:

The <html> tag tells the browser that this is an HTML document.

The html element is the outermost element in HTML and XHTML documents. The html element is also known as the root element.

 

Specific Attributes:

Attribute Definition
version Specifies the HTML DTD version of the document. The version attribute is deprecated - use the !doctype tag instead.
content Specifies the property's value.
scheme Specifies a scheme to use to interpret the property's value (as declared in the content attribute).
http-equiv Used for http response message headers. For example http-equiv can be used to refresh the page or to set a cookie. Values include content-type, expires, refresh and set-cookie.

Other Attributes:

Attribute Definition
lang Specifies a language code for the content in an element.
dir

Specifies the text direction for the content in an element.
Possible Values:

  • rtl  (Right to Left)
  • ltr  (Left to Right)

Example Code:

<html>
<head>
<title>Title of the document</title>
</head>

<body>
The content of the document......
</body>

</html>