HTML5 tutorial - The html tag contains everything in a webpage.

The html tag - the tag that says to computers that what it contains is html.

Now we go to our first "tag". *

With a couple of important exceptions (which we will get into later) all tags have to be opened and closed. Take a look at the code to the right. The opening tag is: <html>. The closing tag is </html> – the difference being the "/" in the closing tag.

Tags are containers. The html tag indicates that everything between <html> and </html> is code that conforms to the standards of the type of HTML dictated by the doctype declaration – in this case HTML5.

Everything between the opening tag and closing tag are inside that tag and therefore have the attributes that tag gives them. Those attributes can be modified. For example in this site I have changed the default color (black) for the </html> tag to dark blue.

Inside the <html> tag are two other important tags:
the <head> tag
the <body> tag

First let's take a look at the <head> tag.

tag or element *

Tags or elements may represent headings, paragraphs, hypertext links, lists, embedded media, and a variety of other structures.
wikipedia

* What is popularly called a "tag" probably should be called an "element" with opening and closing tags. In other words the "html element" has an "opening tag" and a "closing tag". The problem is that no one uses the word "element" except those in W3C and WHATWG. I am sticking with "tag". It has served me well for the last twelve years and I see no reason to change now.