Omitting the html, head, and body tagsOmitting the html, head, and body tags is certainly allowed by the HTML specs. The underlying reason is that browsers have always sought to be consistent with existing web pages, and the very early versions of HTML didn't define those elements. When HTML
In the HTML5 standard, the <html> tag, the <body> tag, and the <head> tag can be omitted. The following code will validate as HTML5:
<!DOCTYPE html> <title>Page Title</title> <h1>This is a heading</h1> <p> This is a paragraph. </p>
More details: Stackoverflow: Is it necessary to write HEAD, BODY and HTML tags?