E.g.
languages:
en:
title: "My Thing"
copyright: "© 2025 My Company. All rights reserved."
es:
title: "Mi Cosa"
copyright: "© 2025 Mi Compañía. Todos los derechos reservados."
E.g.
languages:
en:
title: "My Thing"
copyright: "© 2025 My Company. All rights reserved."
es:
title: "Mi Cosa"
copyright: "© 2025 Mi Compañía. Todos los derechos reservados."
What prevents you from putting it where you want it?
It seems to me that the same question could be asked of the site title, and the answer is the same.
Correction: for some reason I has missed that site.Copyright
is a thing.
It should work by setting language specific params like this:
languages:
en:
title: "My Thing"
params:
copyright: "© 2025 My Company. All rights reserved."
es:
title: "Mi Cosa"
params:
copyright: "© 2025 Mi Compañía. Todos los derechos reservados."
That’s exactly how copyright is localized. That snippet should work as is with any default templates and themes that make use of .Site.Copyright
. Maybe it’s not clear from the documentation but that also applies to all “root” configuration if I am not mistaken. It certainly does for menus.
That’s exactly how copyright is localized. That snippet should work as is with any default templates and themes that make use of
.Site.Copyright
. Maybe it’s not clear from the documentation but that also applies to all “root” configuration if I am not mistaken. It certainly does for menus.
That isn’t how it works. site.Params.copyright is separate from site.Copyright.
This:
copyright = "© site"
[languages.en]
languagecode = "en-us"
languagedirection = "ltr"
languagename = "English"
weight = 10
[languages.en.params]
copyright = "© en"
[languages.es]
languagecode = "es"
languagedirection = "ltr"
languagename = "Spanish"
weight = 20
[languages.es.params]
copyright = "© es"
and:
{{ site.Copyright }}
produce this for Spanish:
© site
Everything in site.Params is custom.
I don’t understand. This works fine:
[languages.en]
contentDir = 'content/en'
languageCode = 'en-US'
languageDirection = 'ltr'
languageName = 'English'
weight = 1
title = 'My Site (en)'
copyright = 'Copyright (en)'
[languages.de]
contentDir = 'content/de'
languageCode = 'de-DE'
languageDirection = 'ltr'
languageName = 'Deutsch'
weight = 2
title = 'My Site (de)'
copyright = 'Copyright (de)'
{{ .Site.Title }}
{{ .Site.Copyright }}
Fine how? What is the result you see?
To be clear, I’m asking for language copyrights in config because it’s not documented to be there. I’m not sure why you’re setting it in config. Does that actually work? If so, then this is just a case of an omission in documentation.
Yes, it works. Try it yourself.
Many of the configs can be defined per language: title, baseURL, copyright, params, markup, etc, etc, etc.
Thanks. Created doc: not all site language options are documented · Issue #13352 · gohugoio/hugo · GitHub.
We’ll update the documentation in the next week or so, but for now…
There are 69 root config settings, plus 24 tables, for a total of 93.
45 of them can be set per-language:
48 of them cannot be set per-language:
Thanks! Very useful.