HTML Building Blocks

In this tutorial, we are discussing the basics of HTML documents and the building block of the HTML.

What are the building blocks of HTML?

HTML is written in the form of HTML elements, which are formed by using markup tags. These markup elements are a key feature of HTML. Every markup tag, such as <html>, <head>, <body>, <title>, <p> , and so on, is made up of a keyword enclosed by angle brackets. HTML tags are typically used in pairs, such as <html> and </html>. The first tag in a pair is commonly referred to as the opening tag (or start tag), while the second tag is referred to as the closing tag (or end tag). An opening tag and a closing tag are identical, with the exception of a slash (/) following the closing tag's opening angle bracket to indicate to the browser that the command has been performed. You can put relevant material between the start and finish tags.


<tag name  attribute_name= " attr_value"> content </ tag name>
 
  • Tags: An HTML tag surrounds the material and gives it significance. It is enclosed by “<” and “>” brackets.
  • Attribute: In HTML, an attribute gives additional information about the element and is used within the start tag. An HTML attribute is made up of two fields: name and value.
  • Elements: A HTML element is an independent component of an HTML file. Everything written within tags in an HTML file is referred to as an HTML element.
     
HTML - Introduction