A meta description is an html tag which consists of a snippet of text (up to around 155 characters) that summarizes a page’s content. Search engines show meta descriptions underneath the page titles in search results. Meta-descriptions play a big role in search results. In case you're unfamiliar with the term, a meta description is the snippet of information below the link of a search result. Its purpose is to describe the contents of the page to the searcher. The end goal is to convince and persuade the searcher to click through to your website.
Describe metadata within an HTML document:
More 'Try it Yourself' examples below.
<meta> tag defines metadata about an HTML document. Metadata is data (information) about data.
<meta> tags always go inside the <head> element, and are typically used to specify character set, page description, keywords, author of the document, and viewport settings.
Metadata will not be displayed on the page, but is machine parsable.
Metadata is used by browsers (how to display content or reload page), search engines (keywords), and other web services.
There is a method to let web designers take control over the viewport (the user's visible area of a web page), through the
<meta> tag (See 'Setting The Viewport' example below).
|charset||character_set||Specifies the character encoding for the HTML document|
|content||text||Specifies the value associated with the http-equiv or name attribute|
|Provides an HTTP header for the information/value of the content attribute|
|Specifies a name for the metadata|
<meta> tag also supports the Global Attributes in HTML.
Mass effect 3 pc digital download. Define keywords for search engines:
Define a description of your web page:
Define the author of a page:
Refresh document every 30 seconds:
Setting the viewport to make your website look good on all devices:
The viewport is the user's visible area of a web page. It varies with the device - it will be smaller on a mobile phone than on a computer screen.
You should include the following
<meta> element in all your web pages:
This gives the browser instructions on how to control the page's dimensions and scaling.
width=device-width part sets the width of the page to follow the screen-width of the device (which will vary depending on the device).
initial-scale=1.0 part sets the initial zoom level when the page is first loaded by the browser.
Here is an example of a web page without the viewport meta tag, and the same web page with the viewport meta tag:
Tip: If you are browsing this page with a phone or a tablet, you can click on the two links below to see the difference.
You can read more about the viewport in our Responsive Web Design - The Viewport Tutorial.
HTML tutorial: HTML Head
HTML DOM reference: Meta Object