Comments are parts of the code that are ignored by a browser. To explain and define section parts of a document to others who see the code, it's a good practice to add comments to your HTML code. Especially in complex documents. To increase the readability of the code and help others understand the code, then comments are very useful.
<!DOCTYPE html>
<html>
<head>
<title>Comment over one line</title>
</head>
<body>
<!--Comments that span over no more than one line are called a single line comment.-->
<p>Some even better story goes here.</p>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<title>Comment over more than one line</title>
</head>
<body>
<!--
Comments that span over more than one line
is called a multiline comment.
-->
<p>Some nice story goes here</p>
</body>
</html>
<!DOCTYPE html>
<html>
<body>
<!-- Hide this during debugging
<p>Why comments can be good to use during debugging the code.</p>
-->
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<title>Commenting Script Code</title>
<script>
<!--
document.write("My nice friend Johnny is swimming")
-->
</script>
</head>
<body>
<p>Hello , Johnny!</p>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<title>Commenting Style Sheets in HTML</title>
<style>
<!--
.example {
border: 3px solid;
}
-->
</style>
</head>
<body>
<div class = "example">Hello , Johnny! Dinner is served.</div>
</body>
</html>