HTML Tutorial #1: What is HTML, Tags, Elements and Attributes?


HTML is very easy to learn and you can become a skillful person by learning it.  I’ve 5 years of experience of HTML; I’ll share my experience with you. This is the first tutorial of HyperText Markup Language (HTML 4). Tim Berners lee invented HTML in 1990, some says in 1991.  Many languages are used to develop websites but HTML is necessary to learn if you want to become a web developer, HTML is important to learn other web development languages. HTML is the first step to enter in the field of web development. HTML has various versions in market but in this tutorial you will learn HTML 4.


HTML is a Markup language. HTML  makes possible for to present information on internet. HTML can be coded in any text editor like notepad or you can use Notepad++ or Adobe Dreamweaver. HTML is written in form of HTML element, which contains tags. HTML is used to make a simple static web page. There is a misunderstanding about HTML, that many people think it is a programming language but it is not, instead HTML just support browsers not computer.


Normally markup tags are called HTML tags. HTML tags are represented by angle brackets, they begin with a less-than sign “<” and end with a greater-than sign “>” e.g. <html>. There are two types of tags, Pair Tags and Unpaired Tags. Pair tags are represented like this <p> text </p>. First tag is the start tag and second tag is end tag.  Now we can write whatever we want in between these tags, between <p> and </p>.  The end tags always contain a forward slash before the tag name, to show that it is end tag.  Start and end tags are also called opening and closing tags.  Unpaired tags don’t have any opening and closing tags, e.g. <img> is used to insert image and it is an unpaired tag.

HTML Elements

Everything from the start tag to the end tag is called HTML element. Elements give a structure to a HTML document. Some unpaired HTML elements are empty HTML elements like <br> is used for line break. Empty element is always without closing tag.

<h1> Hello World </h1> this is an element.


Attributes are use to add additional information in HTML elements. Attributes are always inserted within the start tag/opening tag. HTML attributes are followed by an equal (=) sign and then the additional information should be written in between quotation marks. A semicolon, after the attribute is used to separate different attributes, like if you want to add another style, for example to want to show that text in red color then just add another attribute (color:#;)  after semicolon. The additional information, which was written in opening tag, is called HTML Attribute.

<h1 style=”background-color: #f1f1f1;”> Hello World </h1>

<h1 style=”background-color: #f1f1f1; color: #FF0000;”> Hello World </h1>


Please feel free to ask anything related to this post.

Journalist, Android Application Developer and Web Designer. Writes article about IT in Roznama Dunya. I Interview Prominent Personalities & Icons around the globe.

Leave a Reply