Site
Returns the Site object.
- Syntax
- PAGE.Site
- Returns
- page.siteWrapper
The Site method on a Page object returns the site to which the page belongs. See Site methods.
{{ .Site.Title }}The returned site is not always the site being rendered. For example, when you range over the translations of the current page, the Site method returns the site of each translation:
{{ range .AllTranslations }}
{{ .Site.Title }}
{{ end }}To simplify your templates, use the global site function to access the site being rendered. Unlike the Site method, the site function is available in any context.
Last updated:
November 2, 2026
:
content: Prefer site function in code examples (3350b883b)
Improve this page