`<head>` HTML document metadata (header) element
The <head> HTML element contains machine-readable information (metadata) about the document, like its title, scripts, and style sheets. There can be only one <head> element in an HTML document.
The **`<head>`** [HTML](/docs/Web/HTML) element contains machine-readable information (metadata) about the document, like its [title](/docs/Web/HTML/Reference/Elements/title), [scripts](/docs/Web/HTML/Reference/Elements/script), and [style sheets](/docs/Web/HTML/Reference/Elements/style). There can be only one `<head>` element in an HTML document.
> [!NOTE]
> `<head>` primarily holds information for machine processing, not human-readability. For human-visible information, like top-level headings and listed authors, see the header element.
## Attributes
This element includes the [global attributes](/docs/Web/HTML/Reference/Global_attributes).
- `profile`
- : The URIs of one or more metadata profiles, separated by white space.
## Examples
```html
<!doctype html>
<html lang="en-US">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width" />
<title>Document title</title>
</head>
</html>
```
## Technical summary
<table class="properties">
<tbody>
<tr>
<th scope="row">
<a href="/en-US/docs/Web/HTML/Guides/Content_categories"
>Content categories</a
>
</th>
<td>None.</td>
</tr>
<tr>
<th scope="row">Permitted content</th>
<td>
<p>
If the document is an iframe
<a href="/en-US/docs/Web/HTML/Reference/Elements/iframe#srcdoc"><code>srcdoc</code></a> document, or if title
information is available from a higher level protocol (like the
subject line in HTML email), zero or more elements of metadata
content.
</p>
<p>
Otherwise, one or more elements of metadata content where exactly one
is a title element.
</p>
</td>
</tr>
<tr>
<th scope="row">Tag omission</th>
<td>
The start tag may be omitted if the first thing inside the
<code><head></code> element is an element.<br />The end tag may be
omitted if the first thing following the
<code><head></code> element is not a space character or a comment.
</td>
</tr>
<tr>
<th scope="row">Permitted parents</th>
<td>An html element, as its first child.</td>
</tr>
<tr>
<th scope="row">Implicit ARIA role</th>
<td>
<a href="https://w3c.github.io/html-aria/#dfn-no-corresponding-role"
>No corresponding role</a
>
</td>
</tr>
<tr>
<th scope="row">Permitted ARIA roles</th>
<td>No <code>role</code> permitted</td>
</tr>
<tr>
<th scope="row">DOM interface</th>
<td>HTMLHeadElement</td>
</tr>
</tbody>
</table>
## Specifications
## Browser compatibility
## See also
- Elements that can be used inside the `<head>`:
- title
- base
- link
- style
- meta
- script
- noscript
- template
Cite this
"` ` HTML document metadata (header) element". MDN Web Docs. CC BY-SA 2.5 (MDN). https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/head JSON record · API collection · BibTeX · RIS · CSL-JSON · citation policy