# UMG - Pixel perfect borders

**URL:** <https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742>\
**Category:** UI\
**Tags:** border, unreal-engine, UI, UE4, question, UMG\
**Created:** [May 7, 2016, 1:30pm UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742 "2016-05-07T13:30:20Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![erebel55](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@erebel55](https://forums.unrealengine.com/u/erebel55)\
**Post date:** [May 7, 2016, 1:30pm UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/1 "2016-05-07T13:30:20Z")

</div>

Is there anyway to do pixel perfect borders that are less than 3 pixels tall? I want to reproduce something like this in UMG.

 ![89746-ui.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/0/2/702278d50ce9d15e9005e4aeaeb9538fda9ad50d.png)

I have tried using the Border widget but it seems to render things at inconsistent heights for some reason.

![89747-borders.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/1/b/c1b7fde6bf0772dc3eca7737760991b37eb3a74d.png)

Here is my UMG hierarchy

 ![89748-border_umg.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/4/9/849842f77da4e83647bd12a83c70f8a6c25fe13d.png)

---

<div class="post-metadata">

**Author:** ![neai](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@neai](https://forums.unrealengine.com/u/neai)\
**Post date:** [June 5, 2016, 11:26am UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/2 "2016-06-05T11:26:02Z")

</div>

As alternative you can try a plain Image widget:

1. for a plain line try white texture with ie 1px height
2. for a pixel perfect border try the box rendering mode & a border texture (literally a texture with 1px white border on the edges and transparency inside)

---

<div class="post-metadata">

**Author:** ![Kakhoofd78](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Kakhoofd78](https://forums.unrealengine.com/u/Kakhoofd78)\
**Post date:** [March 26, 2017, 3:14pm UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/3 "2017-03-26T15:14:41Z")

</div>

Can this be done with the Border widget by now?

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_47ac02bb](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_47ac02bb](https://forums.unrealengine.com/u/anonymous_user_47ac02bb)\
**Post date:** [June 8, 2017, 2:41pm UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/4 "2017-06-08T14:41:29Z")

</div>

did you get anywhere with this? same issue…

---

<div class="post-metadata">

**Author:** ![erebel55](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@erebel55](https://forums.unrealengine.com/u/erebel55)\
**Post date:** [November 29, 2017, 1:31am UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/5 "2017-11-29T01:31:28Z")

</div>

No, I didn’t, sorry.

---

<div class="post-metadata">

**Author:** ![GamesByHyper\_Eric](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/gamesbyhyper_eric/32/709237_2.png) [@GamesByHyper\_Eric](https://forums.unrealengine.com/u/GamesByHyper_Eric)\
**Post date:** [July 3, 2021, 6:02pm UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/6 "2021-07-03T18:02:22Z")

</div>

Have you found it out? Same Issue. So anoying.

---

<div class="post-metadata">

**Author:** ![ameson](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ameson](https://forums.unrealengine.com/u/ameson)\
**Post date:** [October 11, 2021, 4:12pm UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/7 "2021-10-11T16:12:41Z")

</div>

Guys you need to properly setup DPI rendering rules ( [DPI Scaling | Unreal Engine Documentation](https://docs.unrealengine.com/4.27/en-US/InteractiveExperiences/UMG/UserGuide/DPIScaling/) )

That affects how pixel perfect are elements rendered. Depends a lot if you wanna scale them or keep them same in different resolutions, but generally this is the way how to tackle this problem.

---

<div class="post-metadata">

**Author:** ![SK83RJOSH](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SK83RJOSH](https://forums.unrealengine.com/u/SK83RJOSH)\
**Post date:** [October 16, 2025, 3:12pm UTC](https://forums.unrealengine.com/t/umg-pixel-perfect-borders/356742/8 "2025-10-16T15:12:24Z")

</div>

This is simply incorrect. UMG will happily render things at half pixel offsets and mess up thin elements regardless of DPI scaling and pixel snapping. I’ve struggled to find a solution to this for years, and at this point I’m convinced it’s impossible without dropping to the level of C++ or doing custom rendering in OnDraw.
