HTML Tutorial_ Learn HTML For Free
HTML Tutorial_ Learn HTML For Free
HTML Tutorial
HTML is a standard markup language, which stands for Hyper Text Markup
Language. It is widely used language to create webpages. HTML invented by Tim
Berners-Lee in late 1991, but it's first version "HTML 1.0" was released in 1993, and
"HTML 2.0" was the first standard HTML specification, which was published in 1995.
This HTML tutorial covers everything from basic HTML fundamental concepts and tags
to advanced techniques, such as forms, modal boxes, multimedia, and HTML5. This
tutorial is designed to help both beginners and experienced designers become experts in
building dynamic and responsive websites.
What is HTML?
HTML (HyperText Markup Language) is a standard markup language to design the
structure of a webpage. HTML is the combination of HyperText and Markup
Language. HyperText defines the internal links between webpages, and Markup
language defines the layout and presentation of text and media.
Open Compiler
<!DOCTYPE html>
<html>
<head>
<title>Page title</title>
</head>
<body>
<h1>Webpage's Heading</h1>
<p>Content (Your first paragraph).</p>
</body>
</html>
Explore our latest online courses and learn new skills at your own pace. Enroll and
become a certified expert to boost your career.
Page 2 of 10
1. <!DOCTYPE html>
This element defines the document type as HTML. This element must be written before
writing any HTML document.
2. <html>...</html>
The <html> tag is the parent tag for all HTML elements. Everything related to create an
HTML document must be written inside the <html> tag. CSS, JavaScript, and jQuery
must also be written inside this tag.
3. <head>...</head>
The <head> tag is a container tag for all those elements that are not directly displayed
on the webpage but required for the page functionalities. It contains meta tags (which
are used for SEO purposes), title tag, script tags, etc.
4. <title>...</title>
The <title> tag is used to define the title of the webpage that you can see in the
browser's tab, bookmarks list, and search engine results. This tag is also very important
for SEO purposes to help search engine to understand the content of the webpage.
5. <body>...<body>
The <body> tag is the container tag for all those elements, which represents the main
content of a webpage that displays on the browser.
6. <h1>...</h1>
The <h1> tag is one of the heading tags. It is the most important heading tag, which
defines the main title or headline of the webpage. Any text written inside <h1> and
</h1> is a top-level heading of the content.
7. <p>...</p>
The <p> tag defines a paragraph, anything written inside <p> and </p> displays as a
paragraph on the webpage. Use multiple <p> tags to display text in different
paragraphs.
Page 3 of 10
Below is the HTML code to display Hello World on the webpage in a paragraph −
Open Compiler
<!DOCTYPE html>
<html>
<head>
<title>Hello World Example by TutorialsPoint</title>
</head>
<body>
<h1>Hello, World!</h1>
</body>
</html>
</pre>
The above example will display "Hello, World!" on the browser inside top-level heading
(h1).
Comments in HTML
Just like other programming languages, you can keep any text as a comment inside an
HTML document. To create a comment in HTML, use <!-- and -->.
Any text written inside <!-- and --> considers as comment and it does not display on the
website.
Example
Open Compiler
<!DOCTYPE html>
<html>
<head>
<title>Online HTML Editor</title>
</head>
<body>
<h1>Online HTML Editor</h1>
<p>Hello World</p>
</body>
</html>
And, finally, open the file in the browser by typing the file name with a complete path, or
just open it by right-clicking and opening with a browser.
HTML is a MUST for students and working professionals to become great software
engineers, especially when they are working in the web development domain.
Create a web site − You can create a website or customize an existing web
template if you know HTML well.
Understand web − If you want to optimize your website, to boost its speed and
performance, it is good to know HTML to yield the best results.
Learn other languages − Once you understand the basics of HTML, then other
related technologies like JavaScript, PHP, or Angular are easier to understand.
Applications of HTML
As mentioned before, HTML is one of the most widely used languages on the web. Here
are some of the applications of HTML −
Internet Navigation − HTML provides tags that are used to navigate from one
page to another and is heavily used in internet navigation.
Responsive UI − HTML pages now-a-days work well on all platforms, mobile,
tabs, desktops, or laptops owing to responsive design strategy.
Offline support − HTML pages, once loaded, can be made available offline on
the machine without any need of internet.
Game development − HTML5 has native support for rich experiences and is
now useful in the gaming development arena as well.
Experience with any text editor like Notepad, Notepad++, or Edit Plus etc.
Careers in HTML
HTML is the basics for web development. Good knowledge of HTML helps you to build
your career in the following fields −
Front-end developer
Web designer
HTML Quiz
HTML Articles
Explore our 2000+ HTML articles to find the solutions to your web design and
development related problems. Visit: HTML Articles
The full form of HTML is Hypertext Markup Language. It is the standard markup language
for developing web pages.
The HTML tags help search engines understand the content of the web page.
The HTML forms enable user interactions and include call-to-action buttons, text
fields, checkboxes, and many more.
Using HTML, we can embed various types of media like images, audio, video, etc.,
into a web page.
It is also used in the creation of hyperlinks that can point to other web pages,
different sections of the same page, or other resources on the web.
Open a text editor (like Notepad, Sublime Text, Atom, etc.) on your system.
In the dialogue box, choose the location where you want to save the file.
Type a name for your file, followed by the .html extension so that the browser
interprets it as an HTML file. For example, index.html.
Click "Save".
HTML was invented by Tim Berners-Lee, a physicist at CERN, in late 1991. However, the
first standard HTML specification was published in 1995.
Simplicity − HTML is easy to learn and use. It has a clear and straightforward
syntax which makes it simpler for beginners also.
Linking − One of the key features of HTML is the ability to create links to other
web pages.
Integration − HTML works well with other languages that are commonly used in
web development, such as CSS (Cascading Style Sheets) and JavaScript. CSS is
used for styling and layout of web pages while JavaScript is used for interactivity.
localStorage − This object stores data with no expiration date. The data will not
be erased when the browser is closed and will be available in the next session.
sessionStorage − This object stores data for one session. The data is lost when
the browser tab is closed.
To run an HTML file in a browser, first, save your HTML file with a .html extension. For
example, index.html. Then, locate your file and double-click to open it in your default
browser.
Headings − HTML provides six levels of headings from <h1> to <h6>, with
<h1> being the highest (or most important) level and <h6> the lowest.
Links − The <a> tag defines a hyperlink, which is used to link from one page to
another.
Forms − The <form> tag is used to create an HTML form for user input.
Page 10 of 10
Divisions & Sections − The <div> tag is a container unit that encapsulates
other page elements and divides the HTML document into sections. HTML5
introduced semantic elements like <section>, <article>, <header>, <footer>,
<nav>, etc., which serve a similar purpose but provide additional semantic
information.