# 24h time format for ui time input

**URL:** <https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590>\
**Category:** Dashboard\
**Created:** [13 May 2020 11:22 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590 "2020-05-13T11:22:47Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![iungo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/iungo/32/8099_2.png) [@iungo](https://discourse.nodered.org/u/iungo)\
**Post date:** [13 May 2020 11:22 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/1 "2020-05-13T11:22:47Z")

</div>

Is it possible to change time format from 12h to 24h

In some cases there is a problem to change time format in browser (chromium kiosk mode on raspbian lite)

Maybe somebody has any solution?

---

<div class="post-metadata">

**Author:** ![gerry](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gerry/32/21604_2.png) [@gerry](https://discourse.nodered.org/u/gerry)\
**Post date:** [13 May 2020 14:01 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/2 "2020-05-13T14:01:43Z")

</div>

I've read this through several times now and have absolutely no idea what your referring to. Is it the browser, the node red dashboard, inputting into node red from a browser? If you could identify more closely what you are referring to perhaps someone could help. Perhaps screenshot may help as well.

---

<div class="post-metadata">

**Author:** ![iungo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/iungo/32/8099_2.png) [@iungo](https://discourse.nodered.org/u/iungo)\
**Post date:** [13 May 2020 14:11 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/3 "2020-05-13T14:11:36Z")

</div>

It looks like this

![time](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/7/87407ee8992792053bfc73fa9689a9a105b94ef3.png)

I need 24h format.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [13 May 2020 14:14 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/4 "2020-05-13T14:14:37Z")

</div>

Have you taken a look at any of the contrib nodes? There are a couple that would probably work for you.  
or you could use a function node to do it.

---

<div class="post-metadata">

**Author:** ![iungo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/iungo/32/8099_2.png) [@iungo](https://discourse.nodered.org/u/iungo)\
**Post date:** [13 May 2020 14:21 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/5 "2020-05-13T14:21:28Z")

</div>

I think ui-text input node is very convenient for time input.

I don't find any node like this.

Interesting, but ui-chart node has a time format option. But ui-text(time input) doesn't have.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [13 May 2020 14:28 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/6 "2020-05-13T14:28:54Z")

</div>

Sorry, I missed the UI in the title. Currently I see no UI node for entering time, but it's a good idea. It should havet the option to input time in eithor 12 or 24 hour format.

Why don't you write one? It would be a great addition.

---

<div class="post-metadata">

**Author:** ![iungo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/iungo/32/8099_2.png) [@iungo](https://discourse.nodered.org/u/iungo)\
**Post date:** [13 May 2020 14:37 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/7 "2020-05-13T14:37:49Z")

</div>

I'm not so good in javacript. Mostly I write for embedded systems, so C my lang.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [13 May 2020 16:05 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/8 "2020-05-13T16:05:11Z")

</div>

Can you clarify exactly how you are getting that display? I assumed you meant a ui-text node in Time Picker mode, but for me that works in 24hr mode. Perhaps post a mini-flow showing exactly what you are doing.

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [13 May 2020 16:21 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/9 "2020-05-13T16:21:06Z")

</div>

It just uses the browsers built in html5 input - so for me on chrome it is ok.

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/9/b/9b4d5212c9f19c473e301b79883b5d8c8c93a171.png)  
It depends on the overall system locale I think.

---

<div class="post-metadata">

**Author:** ![iungo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/iungo/32/8099_2.png) [@iungo](https://discourse.nodered.org/u/iungo)\
**Post date:** [13 May 2020 16:25 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/10 "2020-05-13T16:25:15Z")

</div>

It works differently on different OS in chrome broser.

WIN 10 English lang chrome - 12h format  
WIN 10 Russian lang chrome - 24h format  
Raspberry Pi, Buster Lite, Chromium - 12h format

```auto
[{"id":"843238d7.baddb8","type":"change","z":"aa895d2c.2a681","name":"16:00","rules":[{"t":"set","p":"payload","pt":"msg","to":"16:00","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":1870,"y":1560,"wires":[["dcc5e0fa.7ec9b"]]},{"id":"dcc5e0fa.7ec9b","type":"ui_text_input","z":"aa895d2c.2a681","name":"","label":"Test Time","tooltip":"","group":"cca3954a.9ac258","order":2,"width":0,"height":0,"passthru":false,"mode":"time","delay":"0","topic":"","x":2040,"y":1560,"wires":[["b6c1358f.8398e8"]]},{"id":"b9b4a3a7.304cf","type":"inject","z":"aa895d2c.2a681","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":0.1,"x":1670,"y":1560,"wires":[["843238d7.baddb8"]]},{"id":"b6c1358f.8398e8","type":"debug","z":"aa895d2c.2a681","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":2270,"y":1560,"wires":[]},{"id":"cca3954a.9ac258","type":"ui_group","name":"Group 1","tab":"4436028d.0ebaac","order":1,"disp":true,"width":6},{"id":"4436028d.0ebaac","type":"ui_tab","name":"Tab 5","icon":"dashboard","order":5}]

```

 ![flow](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/9/59e72a7a345ab46f3304c2cac36218b41bd64fa6.png)

---

<div class="post-metadata">

**Author:** ![iungo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/iungo/32/8099_2.png) [@iungo](https://discourse.nodered.org/u/iungo)\
**Post date:** [13 May 2020 16:35 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/11 "2020-05-13T16:35:49Z")

</div>

I understand it.

But time format on chart works fine independently from system locale.  
Also, my raspbian system locale is system is

~$ date  
Wed 13 May 19:28:16 MSK 2020

changing locale from auto to  
Generating locales (this might take a while)...  
en\_GB.UTF-8... done

Also does nothing

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [12 June 2020 16:49 UTC](https://discourse.nodered.org/t/24h-time-format-for-ui-time-input/26590/12 "2020-06-12T16:49:52Z")

</div>

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