HTML <!--...--> Tag


This tag is mostly used to specify a comment on a document type.

The comment tag <!– Comment –> is used in HTML code to insert comments. It is a good coding technique so that both the developer and the reader may obtain aid understanding the code. It is beneficial to comprehend the complicated code. The comment tag is important for troubleshooting code.

  • It is a basic piece of code that web browsers remove (ignore), i.e. it is not shown by the browser.
  • It aids the writer and reader in comprehending the purpose of a piece of code, especially in complicated source code.

Syntax

Example

Preview

Supported Browsers

Element Chrome Firefox Safari Edge / IE Opera
<!DOCTYPE> Yes Yes Yes Yes Yes