PngNix
EN TR

Guides · 2026-11-21

How to Use Transparent PNG Icons in Unity and Godot

Step-by-step import settings for transparent PNG game icons in Unity and Godot: sprite mode, filtering, compression, mipmaps and fixing dark edges.

A transparent PNG looks simple, but the way you import it decides whether your icon stays crisp in an inventory slot or ends up blurry, with dark halos around the edges. This guide covers the settings that matter for item icons in the two most common indie engines.

1. Start from a large source

Download the largest version you can (our icons are 512 × 512 px). It is always better to let the engine scale an icon down than to scale a small file up. If your slots are 64 px, a 512 px source still gives you room for high-DPI screens, zoomed tooltips and store pages, without making a second file.

2. Unity: import as a sprite

  • Drag the PNG into your Assets folder and select it.
  • Texture Type: Sprite (2D and UI). Sprite Mode: Single.
  • Alpha Is Transparency: on. This makes Unity fill the colour of fully transparent pixels from their neighbours, which removes most dark fringes when the icon is scaled.
  • Max Size: match the largest size you will really display (for example 256 for a 64–128 px slot). Smaller textures use less memory.
  • Compression: for a handful of icons, None or High Quality keeps the colours clean. For hundreds of icons, put them in a Sprite Atlas and compress the atlas instead.
  • Generate Mip Maps: turn it on if the icon is shown at many different sizes (world-space pickups, zooming maps); leave it off for fixed-size UI.

Then use the sprite in a UI Image component and enable Preserve Aspect so tall items such as swords or bottles are not stretched.

3. Godot 4: import settings

  • Select the PNG in the FileSystem dock and open the Import tab.
  • Keep Compress → Mode on Lossless for UI icons. Lossy and VRAM modes are better for large 3D textures than for small UI art.
  • Under Process, enable Fix Alpha Border. It does the same job as Unity's "Alpha Is Transparency" and removes the dark outline that appears when transparent edges are filtered.
  • Click Reimport. Use the texture in a TextureRect with Expand Mode set to fit and Stretch Mode set to Keep Aspect Centered.
  • Texture filtering is set per node or project-wide (Rendering → Textures → Canvas Textures). Use Linear for painted icons; use Nearest only for pixel art.

4. Why dark or white edges appear

Transparent pixels still store a colour. When the engine scales or filters the image, it blends visible edge pixels with those hidden colours. If the hidden colour is black, you see a dark rim; if it is white, a light rim. The "alpha border" options above fix this. If you edit icons in an image editor, avoid exporting with a solid matte colour behind the transparency.

5. Keep a set consistent

  • Use one icon style per screen. Mixing glossy 3D stickers with flat pixel icons in the same inventory looks unfinished.
  • Keep the same padding: our icons are centred with a margin, so they line up in a grid without manual offsets.
  • Use colour to carry meaning (for example red for health, blue for mana) and keep that rule across your whole game.

6. Checklist

  • Large source PNG, scaled down by the engine
  • Sprite / TextureRect with aspect ratio preserved
  • Alpha border fix enabled
  • Lossless or high-quality compression for UI
  • Mipmaps only where the icon changes size at runtime

Related categories

  • Game Icons
  • Level & Rank Icons
  • Medallions & Shields
  • Potions & Magic
  • Weapons & Armor
  • Fantasy MMORPG Items
  • Fantasy Weapons
  • Treasure, Coins & Medals
  • Jewelry & Gems

More guides

  • 9-Slice Scaling for Game UI Frames and Panels
  • Using Animated Stickers and Emojis on Discord, Streams and Websites
  • Game Icon Readability: Size, Colour and Consistency Checklist
© 2026 PngNix
Privacy Cookies Terms Guides Tools About Contact
Free for personal and commercial game projects. No resale or redistribution.

Cookies. We use cookies that are necessary for the site to work. With your permission we also allow third-party cookies to show ads. You can change this at any time. Learn more