# Date translation for multilingual website

**URL:** <https://discourse.gohugo.io/t/date-translation-for-multilingual-website/33981>\
**Category:** support\
**Created:** [July 25, 2021, 11:49am UTC](https://discourse.gohugo.io/t/date-translation-for-multilingual-website/33981 "2021-07-25T11:49:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![L151](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/l151/32/14857_2.png) [@L151](https://discourse.gohugo.io/u/L151)\
**Post date:** [July 25, 2021, 11:49am UTC](https://discourse.gohugo.io/t/date-translation-for-multilingual-website/33981/1 "2021-07-25T11:49:42Z")

</div>

Hi.

I have a multilingual site template that I added a language switcher to. Now I want the months in the publication dates to be translated according to the selected language. What is the easiest way to do this? Didn’t understand anything from the documentation.

---

<div class="post-metadata">

**Author:** ![chrillek](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/chrillek/32/19797_2.png) [@chrillek](https://discourse.gohugo.io/u/chrillek)\
**Post date:** [July 25, 2021, 1:10pm UTC](https://discourse.gohugo.io/t/date-translation-for-multilingual-website/33981/2 "2021-07-25T13:10:22Z")

</div>

Did you see this:

> [@Using i18n for date formatting](https://discourse.gohugo.io/t/using-i18n-for-date-formatting/26704):
>
> I found some tips to use data files for translating month indexes to month names. That works. However, I think it makes more sense to use the i18n function for this. So what I did was to put this in my language toml file: [long\_month\_1] other = "januari" [long\_month\_2] other = "februari" [long\_month\_3] other = "mars" [long\_month\_4] other = "april" [long\_month\_5] other = "maj" [long\_month\_6] other = "juni" [long\_month\_7] other = "juli" [long\_month\_8] other = "augusti" [long\_month\_9] ot…

It’s awkward but seems to be state of the art in Hugo

---

<div class="post-metadata">

**Author:** ![system](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/system/32/1_2.png) [@system](https://discourse.gohugo.io/u/system)\
**Post date:** [July 27, 2021, 1:10pm UTC](https://discourse.gohugo.io/t/date-translation-for-multilingual-website/33981/3 "2021-07-27T13:10:43Z")

</div>

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.
