# Best practice for size of a UI node

**URL:** <https://discourse.nodered.org/t/best-practice-for-size-of-a-ui-node/38482>\
**Category:** Developing Nodes\
**Created:** [3 January 2021 21:49 UTC](https://discourse.nodered.org/t/best-practice-for-size-of-a-ui-node/38482 "2021-01-03T21:49:20Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [3 January 2021 22:29 UTC](https://discourse.nodered.org/t/best-practice-for-size-of-a-ui-node/38482/5 "2021-01-03T22:29:37Z")

</div>

^ what Dave said 🙂

Essentially, take the smaller of width & height then using transform scale, linearly size up to best possible fit in the centre of the UI div.

The beauty of transform scale is it takes care of mouse events and border widths etc etc and literally zooms in/out.

---

_[View the full topic](https://discourse.nodered.org/t/best-practice-for-size-of-a-ui-node/38482)._
