Tutorials

KodeKite Tools

HTML
Flexbox
SVG
Canvas
HTML Tutorial

More


HTML Meta Element
Meta

HTML metadata is used to insert additional important information about a document in a variety of ways. The META elements can be used to include name/value pairs describing properties of the HTML document, such as charset, author, expiry date, a list of keywords, content, document author, document description, auto refresh page after some interval of time, document revison etc. it is an empty element, it has attribute to provide information. you can include any number of meta tags in your document based on what information you want to keep in your document but in general, meta tags do not impact physical appearance of the document, so it depends uopn you wether include meta tags or not.

Meta Charset

You can specify charset for your web page using meta element, charset is a set of characters that will be used within your website. Mostly used charset in website is UTF-8, you can also use charset UTF-16

Syntax

<meta charset=Any charset />


You can use meta elemnet any where within a HTML document.


Example

Meta charset is included in head element

Meta Auther

You can add author name for your web page using meta element, author name is a name of owner of website.

Syntax

<meta name=author content=name of author />


You can use meta elemnet any where within a HTML document.


Example

Meta author name is included in head element

Meta Keywords

You can include your web page keywords using meta element, keywords are the keypoints that are used by search engins to rank your website.

Syntax

<meta name=keywords content=keywords names />


You can use meta elemnet any where within a HTML document.


Example

Meta keywords are included in head element

Meta Description

You can include your web page description using meta element, description is a piece of information about your web page. You can use description to describe for what purpose you have created website or a web page.

Syntax

<meta name=description content=Some information />


You can use meta elemnet any where within a HTML document.


Example

Meta description included in head element

Meta Refresh

You can include your web page auto refreshing document using meta element, refreshing take some interval of time to refresh particular document and time is defined by you in seconds.

Syntax

<meta http-equiv=refresh content=time in seconds />


You can use meta elemnet any where within a HTML document.


Example

Meta refresh document included in head element

Meta Redirection

You can include your page redirection in your website using meta element, page redirection takes some interval of time and url to redirect page to given url after time interval given in seconds.

Syntax

<meta http-equiv=refresh content=time in seconds url=url />


You can use meta elemnet any where within a HTML document.


Example

Meta page redirection included in head element


Meta is a empty element and output of meta element is additional information about web page like you can see in above example.


Practice Task

Open notepad or any other text editor, follow the following points.


  • Create HTML page
  • Add any two html elements
  • Add meta element to auto refresh page after every 5 seconds

save file with name task.html or task.htm and then open it using any browser and see results.


Solution

Meta Auto Refresh Page

It will refresh page after every 5 seconds


Don't forget meta is empty element which means it always comes in single tag.