Option to force 24h/12h format

Since autodetection doesnt work, make an option to force 24h format

The time’s presentation format is determined by the operating system’s locale setting.

Taras, i suggest you read what ppl write. Like i said, it doesnt work. Op’s say it does, but it doesnt.

If it does, it forces you to configure your browser and locale settings In the way you dont want.

Tomi, I invite you to read my forum profile where you’ll see I do read what people write, lots of reading, and lots of writing too.

It works, only not the way you want; you don’t want to re-configure your locale settings.

Much has been written about the complexity of achieving this goal in the linked topic. I wish you luck in convincing a developer to undertake this feature request.

1 Like

Taras,

If it works please tell me which locale setting to adjust to get the hover over to display 24H instead of AM/PM. The history graph is correct and depending on the language setting of the browser but one would assume all of it would depend on the same setting.

Thankful for any pointers in the right direction.

PS. Totally understand about the complexity of rewriting the time settings…

I’d like to bump this feature request as this still is an issue.

Some notes:

  • My Windows is displaying time in 24H format
  • I can’t seem to find any settings in Firefox that relate to showing AM/PM or 24H
  • Most of the world uses 24H clock

Would it be possible to put it somewhere on the roadmap to be able to change between 12/24H?

1 Like

@Skye I was able to get HA switched to 24 hour time using the Language Switch browser plugin on Firefox.

This means I can leave my OS language set to whatever it is and have Firefox send another language to web servers and HA. I had this installed before as I do multilingual web development.

However the British English language code was set incorrectly to en-UK but it should be en-GB. I used the Show My Browser Request Headers to see what Accept-Language header was being sent by the browser.

I know this does not give you the setting you desire in HA but, it may be a acceptable workaround for those that want their computer’s OS language set different language then what they use in their web browser.

Is there a fix for this ? Its so frustrating to get the damn AM/PM format in HA. I have NEVER ever had a problem to get the correct time format in ANY other system/app/os/programming language before.

Yes there is, its called openhab :sweat_smile:

1 Like

I chose a simpler way: I changed the display language from:
Screenshot from 2021-02-14 09-54-20
to:
Screenshot from 2021-02-14 09-54-34

Here’s a graph with display language set to English. Time is in 12-hour format.

Screenshot from 2021-02-14 09-50-59

Here’s the same graph with display language set to English (GB). Time is in 24-hour format.

Screenshot from 2021-02-14 09-55-24


Click on your user account icon (last icon in Home Assistant’s main menu) and Language will appear at the top of the page.

4 Likes

Utterly absurd not having an override for this. There’s clearly a demand here. Also, if you insist on trying to work it out automatically, there’s clearly some problem here because I don’t see this behavior in other web apps.

1 Like

What a cool hint :wink: