Overview
Unity’s default import settings are designed for high-resolution art and will make pixel art look blurry and unprofessional. A specific set of import settings must be applied to every pixel art sprite to maintain crisp, pixel-perfect results. This page covers the critical import settings, sprite sheet slicing, animation setup, and performance optimisation strategies for pixel art games.
Setup
Critical import settings
When any pixel art sprite is selected in Unity’s Project window, the Inspector shows the Texture Import Settings. These must be configured:
| Setting | Correct value | Wrong default | Why |
|---|---|---|---|
| Texture Type | Sprite (2D and UI) | Default (Texture) | Required for 2D sprite rendering |
| Filter Mode | Point (no filter) | Bilinear | Prevents pixel smoothing/blurring |
| Compression | None | Normal Quality | Prevents compression artefacts |
| Generate Mip Maps | Disabled | Enabled | Mip maps blur pixel art at distance |
| Pixels Per Unit | One project-wide value, usually the tile size | 100 | Controls in-world scale |
The single most important setting is Filter Mode: Point. Without it, Unity interpolates between pixels when scaling, which blurs the art entirely.
Pixels Per Unit determines how many sprite pixels equal one Unity unit:
- Pick one PPU for the whole project, usually your tile size: with a 16×16 tile grid, set PPU to 16 so one tile is one unit
- Use that same PPU on every sprite, whatever its size. A 32×32 character in a PPU-16 project is simply 2×2 units; giving it PPU 32 would shrink it to one unit and make its pixels half the size of the tiles’ pixels
- Consistent PPU across all sprites keeps every texel the same size in the world, so characters and tiles align on one pixel grid (and should match the Assets Pixels Per Unit on the unity-pixel-perfect-camera)
Sprite sheet configuration
For animated characters, all animation frames are typically packed into a single sprite sheet PNG.
Slicing setup:
- Select the sprite sheet in Project window
- Set Sprite Mode to Multiple
- Open Sprite Editor
- Use Slice → Type: Grid By Cell Size and enter the frame dimensions (e.g. 32×32)
- Apply — Unity creates individual sprite entries for each frame
- Apply all import settings as above to the sheet itself
Naming convention: Unity names sliced sprites SheetName_0, SheetName_1, etc. Rename them clearly (e.g. player_walk_0 through player_walk_7) for maintainable animation setup.
Getting art in from Aseprite
Aseprite is the most common pixel-art editor on the course, and there are two routes from it into Unity. Both must end with the same import rules as above: Point filtering, no compression, and the one project-wide PPU.
| Route | How | Strengths | Watch out for |
|---|---|---|---|
| Aseprite Importer (recommended) | Save the .aseprite file straight into Assets; Unity’s 2D Aseprite Importer package (part of the 2D feature set) imports it | Every Aseprite tag becomes an Animation Clip with the frame durations from Aseprite; saving in Aseprite updates Unity; Tile Set mode turns Aseprite tilemap layers into Unity tiles | Pixels Per Unit defaults to 100: change it to the project PPU on every file. Filter Mode (Point) and Compression (None) are already correct by default |
| PNG sprite sheet | In Aseprite, File → Export Sprite Sheet on a regular grid at 100% (1×) scale, then import the PNG and slice it as described above | Works with any Unity version or engine; simple hand-over | Never upscale on export; animations and frame timings must be rebuilt by hand in Unity |
(Unity Technologies, Aseprite Importer manual: Importer Features; Aseprite, Aseprite Docs: Sprite Sheet.) Full settings, the tag-to-clip workflow, looping and animation events are on unity-aseprite-importer.
Whichever route you use, scaling up to the screen is the camera’s job, not the art file’s: export at 1×, keep one PPU, and let the unity-pixel-perfect-camera apply whole-number scaling.
Usage
Matching a tileset to the game resolution
For Tilemap-based pixel art, the important thing is not just “resolution” in the abstract. It is that the tileset, camera, and scene scale all agree on the same pixel grid.
Practical rule:
- choose a consistent tile size such as
16x16or32x32 - set Pixels Per Unit to match that tile size
- use that same PPU value on every other sprite that shares the scene, including larger characters and props
- then use unity-pixel-perfect-camera to present that grid cleanly on screen
If those values drift apart, tiles can look crisp in isolation but still align badly in the scene.
Animator Controller setup
Unity’s Animator Controller manages character animation states and transitions:
- Create an Animator Controller asset (right-click Project → Create → Animator Controller)
- Assign it to the Animator component on the character GameObject
- In the Animator window, create states for each animation (Idle, Walk, Jump, Attack)
- Drag animation clips (created from sprite sequences) into each state
- Create transitions between states with appropriate conditions (parameter checks)
- Add parameters (bool, float, trigger) that scripts will set to drive transitions
Common parameters for a 2D character:
| Parameter | Type | Controls |
|---|---|---|
IsMoving | Bool | Idle ↔ Walk transition |
IsGrounded | Bool | Jump entry/exit |
Speed | Float | Blend tree for directional movement |
Hit | Trigger | One-shot hit reaction |
Die | Trigger | Death animation |
See unity-animator-scripting for C# code to drive these parameters.
Animation events
Unity animation events allow clips to trigger game logic at specific frames — useful for:
- Footstep sounds (triggered on contact frames of walk cycle)
- Attack hitbox activation (triggered on the impact frame)
- Particle effects (triggered on specific frames)
Add animation events in the Animation window by clicking the event track at the desired frame.
Current Unity 2D workflow note
Unity’s newer 2D guidance places pixel-art workflows inside a broader package stack that often includes 2D lighting, 2D animation, and URP. That does not replace the core import rules on this page, but it does mean many current pixel-art projects are no longer just “sprites plus Animator” — they may also use 2D lights, skeletal animation, and Shader Graph-based effects where the style supports them. (Unity, How to make a 2D game: art, animation, and lighting for artists, see source-unity-2d-art-animation-lighting)
If you add 2D lights, sprites need the Sprite-Lit-Default material and the camera must use URP’s 2D Renderer. Any normal maps or mask maps you add as secondary textures need the same import settings as the sprite. Lighting also looks different behind a unity-pixel-perfect-camera: with Upscale Render Texture, light falloffs are drawn at the low reference resolution, so they step in visible pixels. Set-up, light types, shadows and pixel-art lighting choices are covered in unity-2d-lighting.
Asset organisation
Professional folder structure for a pixel art game:
Assets/
├── Art/
│ ├── Characters/
│ │ ├── Player/
│ │ │ ├── player_sheet.png ← sprite sheet
│ │ │ └── PlayerAnimator.controller
│ │ └── Enemies/
│ ├── Environment/
│ │ ├── Tileset_Grass/
│ │ └── Tileset_Stone/
│ └── UI/
├── Animations/
│ └── Player/
│ ├── player_idle.anim
│ ├── player_walk.anim
│ └── player_jump.anim
Performance optimisation
Sprite Atlases
A Sprite Atlas combines multiple sprites into a single texture, reducing draw calls. Unity can render all sprites from one atlas in a single draw call instead of one per sprite.
Create a Sprite Atlas (right-click Project → Create → 2D → Sprite Atlas) and add sprites or folders to it. Unity automatically packs them at build time.
Grouping strategy:
- Character atlas — all frames for a given character
- Environment atlas — tiles from a single tileset
- UI atlas — all interface elements
Other optimisation settings
| Technique | Method | Benefit |
|---|---|---|
| Draw call batching | Use Sprite Atlas; ensure sprites share material | Reduces GPU draw calls |
| Animation culling | Set Animator culling mode to “Based on Renderers” | Disables off-screen animation updates |
| Texture compression | Only compress non-pixel-art UI; use None for sprites | Avoids artefacts on low-colour art |
Gotchas
- Bilinear/Trilinear filter mode — the most common mistake in student projects; always verify Point is set after importing
- Wrong Pixels Per Unit — characters and tiles that misalign in the scene usually have mismatched PPU settings
- Mip maps enabled — sprites that look fine up close but blur when the camera zooms out have mip maps accidentally enabled
- Sprite Mode: Single on a sprite sheet — if the Animator shows only one frame, the Sprite Mode was not set to Multiple before slicing
- Compression artefacts — subtle colour banding or blurring visible in the exported build but not the editor; set Compression to None for pixel art sprites
Related
- pixel-art-fundamentals — pixel art design before import
- pixel-art-animation — creating sprite sheets for import
- pixel-art-environment-art — tile assets for Unity’s Tilemap system
- unity-tilemap — editor workflow for painting those imported tiles into levels
- unity-pixel-perfect-camera — camera-side tool for keeping a pixel-art scene aligned to the intended pixel grid
- unity-aseprite-importer — importing
.asepritefiles directly, with tags turned into Animation Clips - unity-animator-scripting — driving animations from C# code
- unity-inspector-references — wiring Animator and SpriteRenderer references
- unity-urp-overview — current render-pipeline context for 2D lighting and effects
- unity-2d-lighting — Light 2D, the 2D Renderer, normal maps and 2D shadows for lit pixel-art scenes
- source-2d-game-graphics-course