Identifies the document as containing HTML elements. | HTML 2, 3.2, 4, 4.01, 5 |
HTML Syntax
<html>
<head> ... </head>
<body> ... </body>
The <html
> element identifies the file as an HTML document.
All HTML documents should start with the <html> tag and end with the </html> tag.
An <html
> element’s start tag can be omitted if the first thing inside the <html
> element is not a comment.
An <html
> element’s end tag can be omitted if the <html> element is not immediately followed by a comment.
The <html>
element supports the following attributes, in addition to global attributes common to all HTML elements.
xmlns | http://www.w3.org/1999/xhtml | Specifies the XML namespace attribute (If you need your content to conform to XHTML) |
<html>
<head>
<title>Sample HTML document</title>
</head>
<body>
<p>Hello, World.</p>
</body>
</html>
Show me
HEAD BODY TITLE