Metadata is simply, information about data. In HTML documents, theelement provides information to browsers about the HTML document. Metadata information will not be displayed on the page but will be used by the web browser in some form or fashion.

Meta elements are used for various reasons such as adding, keywords, a page description, the author of the document, when it was last modified, and other related information. Theelement is always placed within the head element as shown here:

My Web Page Title

Main heading

Here are some of the more common meta elements you’ll be including in your HTML document. There are many more, and you can define your own in a schema.

This tag is used to add copyright information to your page.

Description

Search engines sometimes choose to use descriptions to show them the results of searches. Having a description will help your users have a better understanding of the page so they would be more likely to click on your link.

Generator

This tag is not required, but if you use a web publishing application, the application itself may add this tag to your document.

Googlebot

This attribute informs the Google search engine about indexing, archiving, and link-following rules.

  • noarchive – Prevents Google search engine from archiving the page.nofollow – Informs Google that the page can be indexed, but links should not be followed.noindex – Google robots should follow links, but not index the page.nosnippet – Prevent Google search engine from saving snippets and archiving the document.

Keywords

Keywords tell the web crawler what the main focus is of the document. It can be used by search engines, although many search engines stopped using keywords with regard to indexing your pages.

Refresh

The web page will display for a specified amount of time before refreshing or switching to a new URL. Note: for redirecting pages, it is preferable to use a URL rewriting method.

Using this meta attribute requires the browser to support it. It may not work for all of your visitors.

Web Page Title

This page has moved to a anotherhost.example.com.

Robots

This tag is not required but can be used if you want to instruct web spiders on how to, or not to crawl your site. Valid values for the CONTENT attribute are: INDEX, NOINDEX, FOLLOW, NOFOLLOW.

Multiple comma-separated values are allowed, but obviously, only some combinations make sense. If there is no robotstag, the default is INDEX,FOLLOW, so there’s no need to use this tag if that is your intention. Other possibilities include:

For more detailed information about meta and additional attributes, please visit W3.org’s page concerning this topic.