HTML For Beginners The Easy Way: Start Learning HTML
What is HTML?
HTML, short for Hypertext Markup Language, is the standard markup language used to create web pages. HTML is a markup language used to create web pages. It is used to structure content on the web and provide meaning and context to that content.
History of HTML.
HTML was first created by Tim Berners-Lee, Robert Caillou, and others starting in 1989. It stands for Hyper Text Markup Language.
Hypertext means that the document contains links that allow the reader to jump to other places in the document or to another document altogether. The latest version is known as HTML5.
What do you need to get started?
To get started with HTML, you will need a few basic tools:
VS code: You can use VS code to create HTML code.
A web browser: You will need a web browser to view your HTML output. Popular web browsers include Google Chrome, Mozilla Firefox, and Microsoft Edge.
Setting up your development environment
Before you can start writing HTML code, you will need to set up your development environment. Here are the steps to get started:
Install VS code: Download and install vs code and open vs code and install some other extensions. Live server and Prettier.
Create a folder for your HTML documents: Create a folder on your computer to store your HTML documents.
Creating your first HTML document
Now that you set up your development environment, it's time to create your first HTML program.
Open your editor and create a new file.
<!DOCTYPE html>
<html>
<head>
<title>My First HTML Document</title>
</head>
<body>
<h1>Hello, World!</h1> <p>This is my first HTML page</p>
</body>
</html>
Save the file with a .html
extension. For example, you could save the file as index.html
. Then enter the Go live and your output printed.
Understanding HTML structure
<!DOCTYPE html>: This is the document type declaration, which tells the browser that this is HTML document.
<html>: This is the root element of HTML document, which cantinas all the other elements.
<head>: This element contains metadata about the document, such as the title, charset, and link to external stylesheets or scripts.
<title>My First HTML Document</title>: This line sets the title of the page, which appears in the browser tab.
<body>: This element contains the content of HTML document.
<h1>Hello, World!</h1>:This is a heading element, which displays the text in a large font size.
<p>This is my first HTML page</p>: This is a paragraph element, which display a block of text.
Subscribe to my newsletter
Read articles from omkar Pathak directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by