Iam_
asked

Expert
Kelish Rai answered
In HTML, the slash (/) in a tag indicates that it is the closing tag for an element. This is required because HTML uses pairs of tags to define where an element starts and ends.
For example,
<p>This is a paragraph.</p>Here, <p> marks the start of the paragraph, and </p> marks the end. The content in between these tags—This is a paragraph.—is defined as a paragraph.
Without the closing </p> tag, HTML wouldn't know where the paragraph ends, which could cause formatting issues or incorrect rendering.
Hope this clears things up. Let me know if you have more questions.
HTML
This question was asked as part of the Learn HTML course.
Our Experts
Sanjeev PanditPrincipal Engineer
Sudip BhandariHead of Growth/Marketing
Apekchhya ShresthaSenior Product Manager
Anuj ShresthaTech Lead
Kelish RaiTechnical Content Writer
Abhilekh GautamSystem Engineer
Palistha SinghTechnical Content Writer
Sarthak BaralSenior Content Editor
Saujanya Poudel
Abhay Jajodia
Nisha SharmaTechnical Content Writer
Udayan ShakyaTechnical Content Writer