Skip to content

Essential HTML Tags for Beginners

Posted on:April 4, 2023 at 11:00 AM

HTML (Hypertext Markup Language) is the standard markup language used to create web pages. In this article, we’ll take a closer look at some of the basic HTML tags that are used to create web pages.

Table of contents

Open Table of contents

Headings

Headings are used to define the headings or titles of different sections of a web page. There are six levels of headings, with <h1> being the most important and <h6> being the least important.

Here’s an example of using headings in an HTML document:

<!DOCTYPE html>
<html>
  <head>
    <title>Page Title</title>
  </head>
  <body>
    <h1>Main Heading</h1>
    <h2>Subheading</h2>
    <h3>Sub-subheading</h3>
  </body>
</html>

Paragraphs

Paragraphs are used to define blocks of text in a web page. The <p> tag is used to define a paragraph.

Here’s an example of using paragraphs in an HTML document:

<!DOCTYPE html>
<html>
  <head>
    <title>Page Title</title>
  </head>
  <body>
    <p>This is the first paragraph.</p>
    <p>This is the second paragraph.</p>
  </body>
</html>

Links are used to create clickable links to other web pages, files, or email addresses. The <a> tag is used to create links.

Here’s an example of using links in an HTML document:

<!DOCTYPE html>
<html>
  <head>
    <title>Page Title</title>
  </head>
  <body>
    <p>Visit <a href="<https://www.example.com>">Example</a> for more information.</p>
  </body>
</html>

Images

Images are used to add images to a web page. The <img> tag is used to add images.

Here’s an example of using images in an HTML document:

<!DOCTYPE html>
<html>
  <head>
    <title>Page Title</title>
  </head>
  <body>
    <img src="image.jpg" alt="Image Description">
  </body>
</html>

The src attribute specifies the URL of the image, while the alt attribute provides a text description of the image for users who can’t see it.

Conclusion

In conclusion, understanding basic HTML tags is essential for creating web pages. Headings are used to define the headings or titles of different sections of a web page. Paragraphs are used to define blocks of text. Links are used to create clickable links to other web pages, files, or email addresses. Images are used to add images to a web page. By mastering these basic concepts, you’ll be well on your way to creating your own web pages.

What’s next?

In the coming article, we will be covering the Semantic HTML tags in depth. Don’t forget to follow and share this with your friends that are just starting their web development journey