HTML Comments

A web browser ignores comments, which are a type of code.

Comments aid in code comprehension.

Every programming language has a specific way of commenting.

We utilise the!<!– content –> tag in HTML. Any text inserted between these brackets will be considered a comment.

“Ctrl + /” is the shortcut key. This will automatically add a comment on the content we’ve chosen.

Single comments and multiline comments are the two different categories of comments.

Single-line comments

Are those that are contained entirely within a single line.

<!– Single line Comment –>

Multi-line comments:

Comments that span multiple lines are referred to as multi-line comments.


This is a multiline comment.

You can add as many as lines you want.


Shubhajna Rai
Shubhajna Rai

A Civil Engineering Graduate interested to share valuable information with the aspirants.

Leave a Reply

Your email address will not be published. Required fields are marked *

Get the latest updates on your inbox

Be the first to receive the latest updates from Codesdoc by signing up to our email subscription.