HTML comments have the following syntax:
<!-- this is a comment tag -->
<!-- and so is this one,
which occupies more than one line -->
White space is not permitted between the markup declaration open delimiter ("<!") and the comment open delimiter ("--"), but is permitted between the comment close delimiter ("--") and the markup declaration close delimiter (">").
A common error is to include a string of hyphens ("---") within a comment. Authors should avoid putting two or more adjacent hyphens inside comments.
Information that appears between HTML comments tags has no special meaning (e.g., character references are not interpreted as such).
Note that HTML comments are treated as markup by indexing spiders.
Admin Note: There has been a myth that has perpetuated over the years where keywords and keyword phrases listed inside HTML comments tags would add a boost to the overall relevancy of the page. This is not true based on numerous tests we've performed during the years 2002 and 2003.
HTML comments are just that, they are comments about the HTML/XHTML. Comments are typically used by web site authors/developers to assist one another in providing information relevant to blocks of html content. They are used in the design process to show the start and end tags for different sections of a web page.
Comments tags are also generated by various WYSIWYG software programs. Those comments tags may initiate some form of server side scripting language. For example, the FrontPage <!--webbot bot--> tags which are wrapped inside HTML comments.
HTML comments are not to be used for stuffing keywords and keyword phrases. Since they are treated as HTML markup by indexing spiders, they provide no benefit from an SEO/SEM point of view. In fact, the extra code for the HTML comments just adds to the overall page weight and may possibly negate other page factors.
Last modified: 2008-01-20T19:38:11-0800