HTML Comment Tag

 

HTML Comment Tag

HTML comment tag | HTML comment examples | HTML comment code generator

 

 

HTML comment tag

<!-- This is an HTML comment -->

Comment open delimiter:

<!--

Comment close delimiter:

-->

 

HTML comment examples

Informative text comments

Use informative text comments when you want to add explanations to the code.

The HTML code:

<!-- this is a single line comment -->
<p> some text ... </p>
<!--
    this is
    a multiline
    comment
-->
<p> some more text ... </p>

 

The result page view:

some text ...
some more text ...

 

Code commenting

Use code commenting when you want to keep the code inactive.

The HTML code:

<!-- <p> some text ... </p> -->
<!--
<p> some text ... </p>
<p> some text ... </p>
-->
<p> some more text ... </p>

 

The result page view:

some more text ...

 

HTML comment code generator

Enter text/code to comment:
Select commenting type:
Generated comment code:

 

See also