<meta>: Element metadanych na poziomie dokumentów

Element HTML <meta> reprezentuje metadane, które nie mogą być reprezentowane przez inne elementy związane z metadanymi w HTML, takie jak <base>, <link>, <script>, <style> lub <title>.

Kategorie treści Metadata content. If the itemprop attribute is present: flow content, phrasing content.
Dozwolona zawartość None, it is an empty element.
Pominięcie znacznika As it is a void element, the start tag must be present and the end tag must not be present.
Dozwoleni rodzice <meta charset>, <meta http-equiv>: a <head> element. If the http-equiv is not an encoding declaration, it can also be inside a <noscript> element, itself inside a <head> element.
Domniemane role ARIA No corresponding role
Dozwolone role ARIA No role permitted
Interfejs DOM HTMLMetaElement

The type of metadata provided by the meta element can be one of the following:

  • If the name attribute is set, the meta element provides document-level metadata, applying to the whole page.
  • If the http-equiv attribute is set, the meta element is a pragma directive, providing information equivalent to what can be given by a similarly-named HTTP header.
  • If the charset attribute is set, the meta element is a charset declaration, giving the character encoding in which the document is encoded.
  • If the itemprop attribute is set, the meta element provides user-defined metadata.


This element includes the global attributes.

Note: the attribute name has a specific meaning for the <meta> element, and the itemprop attribute must not be set on the same <meta> element that has any existing name, http-equiv or charset attributes.

This attribute declares the document's character encoding. If the attribute is present, its value must be an ASCII case-insensitive match for the string "utf-8".
This attribute contains the value for the http-equiv or name attribute, depending on which is used.

Defines a pragma directive. The attribute is named http-equiv(alent) because all the allowed values are names of particular HTTP headers:


The name and content attributes can be used together to provide document metadata in terms of name-value pairs, with the name attribute giving the metadata name, and the content attribute giving the value.

See standard metadata names for details about the set of standard metadata names defined in the HTML specification.


<meta charset="utf-8">

<!-- Redirect page after 3 seconds -->
<meta http-equiv="refresh" content="3;url=https://www.mozilla.org">


Specification Status Comment
HTML Living Standard
The definition of '<meta>' in that specification.
Living Standard

Browser compatibility

BCD tables only load in the browser