1 min read · Free · No login needed
An HTML comment is a note you write in your code that the browser completely ignores. Visitors never see it. Only someone reading your source code can see it.
A comment starts with <!-- and ends with -->:
<!-- This is a comment -->
<!-- Header starts here --> so others can find things fast.Comments can span many lines. But never put -- inside a comment, because the browser will think the comment ends there. And remember: comments are visible to anyone who views your page source, so never put passwords, secret keys, or private information in a comment.
<!DOCTYPE html>
<html>
<head>
<title>Comments</title>
</head>
<body>
<!-- This heading is the page title -->
<h1>Welcome</h1>
<!-- <p>This paragraph is hidden and will not show.</p> -->
<p>This paragraph is visible.</p>
</body>
</html>
test.html, open it in your browser, and change the text to see what happens. That is how you learn — by changing things and watching the result.Finish all 30 lessons, pass the test (80%), pay ₹10 and get your certificate.
Take the testFree tutorials teach you the basics. Our paid courses add live projects, mentorship and a certificate.
Browse all coursesAsk about courses, website & more
Request human callback:
Download karne ke liye login karo. Login ke baad yahi page pe rahoge!
Naya ho? Register karo →