24hr format instead of AM/PM in Europe

The sad thing is that the calendar is a relatively new feature. And yet - the calendar always starts the weeks on Sundays. But the real world is diverse and actually few countries start weeks on Sundays. It is actually more common to see weeks starting on Mondays or even Saturdays. These things should be configurable.
It was a huge step forward when I could choose UK English in Home Assistant and see my dates in a proper format and time in 24 hour format. Thank you for that to those that fixed that.

1 Like

I replied to @WoJWoJ not the entire thread and the fix should have fixed his issue. :wink:

Ok, thanksalot for the explanations. I’m reading further. I see all kinds of threads regarding “locale” settings. The thing is every user has it’s personal preferences. At this moment it’s not important for me weeks starting on a wrong day (because it is wrong only based on location, or where you were born) because I don’t use the calendar that much. Maybe it will become more annoying later. At this moment there are:

  • weeknumer (ISO/EU vs America) (week 1 = week with 1 jan or 4 jan)
  • week-start-with sa-su-mo
  • 24h/12h clock
  • dates written like Americans do mm/dd/yyyy or most of Europe dd/mm/yyyy or dd.mm.yyyy (I for myself like ISO notation yyyy-mm-dd because it sorts nicely text-wise) and I always use a preceding zero…
  • temperature ( C / F )
  • distance Meters / Miles
  • numbers: 1.000.000,00 or 1,000,000.00 or 1 000 000.00
  • everything I forgot…

All the combinations of al strange settings are prefered by al kinds of different users. There is no one setting that fits everyone. The “locale” tried to overcome this, but it’s a pain-in-the-a. It’s not helping because it’s hard setting. It is NOT changeable by the user. There is no such locale that suits my preferences.

So my question, where can I join the develop-team to give it a go…

7 Likes

github, where I linked the last PR

1 Like

Hi,
I’m really glad the 24h clock issue is now fixed most of the places.
However I just found one minor annoyance where it was probably forgotten:
When clicking an input_datetime helper:
time-error

Yep, can you please write this up on github as an issue?

I experienced the same issue until I performed the magical “refresh browser cache”. After that all times were in 24 hour format :smiley:

Even for input_datetime details? I tried refreshing, and even another browser.
I will check tomorrow if anyone have reported it as an issue, and I will do it if not.

Please fix this bug. I have never ever had any problems getting a system/app/os/programming l to let me choose the time format i want.

I live in Sweden, If i set swedish as language in HA i get 24h clock. But i want to use english but then i get am/pm time format. Is it possible to use English language and get 24h clock? Thx…

2 Likes

Set it to English (GB).

For more information, see this post:

1 Like

Like mentioned a couple of times, set your language to English (GB) instead of English for the 24h time format.

There must be something wrong, as in my case it doesn’t work.

Ok, so I tried “solution” with English (GB). I have got what I want (24h format).

I’ve read the thread until the end and honestly I was not able to switch Chrome to display dates in logbook in 24H format.
Chrome sends the following in request header:

Accept-Language: en-GB,en;q=0.9,nl;q=0.8

I cannot remove “en” from that list because this is default Chrome language.
In console (opened for HASS website) I get the following:

> window.navigator.language
"en-GB"
> new Intl.DateTimeFormat().resolvedOptions().locale
"en-US"
> new Date().toLocaleTimeString()
"11:15:20 PM"

The only where “en-US” can leak from is that it is a Windows System language (used for Windows interface). The user’s region is set to UK.

The same difficulty with Home Assitant app for Android which does not display history in 24H format. In App Settings one can find the language settings with two choices: “Device Language” and “English (en)”. My device language is “English (United Kingdom)”.

I will appreciate if one succeeded with any above.

P.S. I cannot test Firefox, because Home Assistant UI simply does not work (files with message can’t establish a connection to the server at wss://hass.website/api/websocket in console however network log is error free, probably that is issue 8318).

Let’s upvote this feature request…

3 Likes

There’s a PR open to enable this:

5 Likes

And it’s merged into dev, which means it would typically be part of the next release!

Thanks @spacegaier and @Bram_Kragten for your work on this!

2 Likes

For implementing the 24 hours as a user setting…

@spacegaier I love you!

Sorry, can’t seem to find where this is fixed :slight_smile:
How do I enable 24 hour format ?