# next/head
Examples
We expose a built-in component for appending elements to the `head` of the page: ```jsx import Head from 'next/head' function IndexPage() { return (
My page title

Hello world!

) } export default IndexPage ``` To avoid duplicate tags in your `head` you can use the `key` property, which will make sure the tag is only rendered once, as in the following example: ```jsx import Head from 'next/head' function IndexPage() { return (
My page title

Hello world!

) } export default IndexPage ``` In this case only the second `` is rendered. > The contents of `head` get cleared upon unmounting the component, so make sure each page completely defines what it needs in `head`, without making assumptions about what other pages added. > `title` and `meta` elements need to be contained as **direct** children of the `Head` element, or wrapped into maximum one level of ``, otherwise the meta tags won't be correctly picked up on client-side navigations.