# Dynamically change Gauge Units

**URL:** <https://discourse.nodered.org/t/dynamically-change-gauge-units/46517>\
**Category:** Dashboard\
**Created:** [31 May 2021 16:01 UTC](https://discourse.nodered.org/t/dynamically-change-gauge-units/46517 "2021-05-31T16:01:22Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![E1cid](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/e1cid/32/77971_2.png) [@E1cid](https://discourse.nodered.org/u/E1cid)\
**Post date:** [31 May 2021 17:25 UTC](https://discourse.nodered.org/t/dynamically-change-gauge-units/46517/2 "2021-05-31T17:25:13Z")

</div>

Here is one way

> [@Dynamically change Gauge Units value](https://discourse.nodered.org/t/dynamically-change-gauge-units-value/46260/3):
>
> The unit field will not take mustache template. but you can use {{speed\_var}} {{speed\_unit}} in the value format field

example

```auto
[{"id":"a005a8da.bc11d8","type":"ui_gauge","z":"c74669a0.6a34f8","name":"","group":"8b5cde76.edd58","order":4,"width":0,"height":0,"gtype":"gage","title":"gauge","label":"","format":"{{payload}} {{unit}}","min":0,"max":"40","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":300,"y":4760,"wires":[]},{"id":"6e1dad61.9521f4","type":"inject","z":"c74669a0.6a34f8","name":"","props":[{"p":"payload"},{"p":"unit","v":"°C","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"24","payloadType":"num","x":120,"y":4800,"wires":[["a005a8da.bc11d8"]]},{"id":"8b5cde76.edd58","type":"ui_group","name":"","tab":"8f03e639.85956","order":1,"disp":true,"width":"12","collapse":false},{"id":"8f03e639.85956","type":"ui_tab","name":"Home","icon":"dashboard","disabled":false,"hidden":false}]

```

---

_[View the full topic](https://discourse.nodered.org/t/dynamically-change-gauge-units/46517)._
