In a painting, a line is a stroke. In pixel art, a line is a staircase. Every diagonal you draw breaks down into little horizontal or vertical runs of pixels, and the eye reads those runs very precisely. If they follow a pattern, the line looks straight and calm. If they don’t, the line looks broken, even when it’s only off by one pixel.
That’s why clean lines are the first craft skill after the basics. Outlines, shading edges, silhouettes, isometric tiles: all of them are built from the same staircases. The Pixel Art Fundamentals touch on this in a few sentences. This tutorial goes all the way: you’ll keep lines one pixel thick, build straight lines from equal segments, find jaggies and fix them by moving a single end point, and draw curves that read smooth at 100 % zoom.
What You’ll Need
- A pixel art editor (I use Aseprite. If you’re new to it, see the Aseprite beginner guide.)
- The basics from Pixel Art Fundamentals—canvas setup and the pixel grid
- A small practice canvas, for example 64×64 pixels, with the grid turned on
- 30 minutes
Step 1: Learn to Read a Line as Segments
Zoom in on any diagonal pixel line and you’ll see that it’s made of segments: runs of pixels in one row (or one column), each run shifted by one pixel from the last. A line that goes two pixels across, then one up, then two across, then one up has segments of length 2.
Counting segments is the single most useful habit in this tutorial. Write the lengths down as a sequence, from one end of the line to the other: 2 2 2 2 2. Once you think in sequences, every rule below becomes easy to check. You don’t have to judge whether a line “looks right”. You count.
Try it now: draw a few diagonal lines freehand on your practice canvas, zoom in, and write down the segment sequence of each. You’ll probably find sequences like 2 3 2 2 1 3. Hold on to them. By the end of this tutorial you’ll know what’s wrong with them and how to fix them.
Step 2: Keep Lines One Pixel Thick
Before you worry about angles, check thickness. Brandon from Tiny Warrior Games puts the basic rule plainly in a post on line-art cleanup: “stick to 1 pixel thick lines”.
What does one pixel thick mean on a diagonal? skeddles’ outlines tutorial on Lospec gives the trick: the segments of the line only connect diagonally. Where one segment ends, the next one starts one row up and one column over, touching only at the corner.
The left line in the diagram has an extra pixel at every step. Each one makes a little L-shaped corner, and the line looks thicker and more stair-stepped than it is. This happens all the time when you draw freehand with a mouse or tablet, because your hand doesn’t move in perfect pixel steps.
The fix is pure cleanup: find every spot where two segments touch side by side instead of corner to corner, and delete the extra pixel. On the right, that’s all that changed.
There’s one deliberate exception. The Lospec tutorial notes that you can break the diagonal rule at a corner to create a point, for example at the tip of a spear or the corner of a crate. That’s a choice you make on purpose for a sharp shape, not something that happens by accident along a smooth line.
Lines don’t have to be one pixel thick, of course. Thick outlines are a valid style. But thick lines are built from the same staircases, so learn the one-pixel version first.
Step 3: Build Straight Lines From Equal Segments
Now for the angles. In a thread on the Aseprite forum about making straight and curved lines, the forum user eishiya sums up the core rule: draw lines from segments of equal size, “e.g. slopes of 1/2, 1/3, 1/4, 1/5”. The Lospec tutorial says the same about straight diagonals: they should be made up of identical segments.
The diagram at the top of this tutorial shows the lines you’ll use again and again:
- 1:1: one across, one up. The perfect 45° diagonal, a single pixel per step.
- 1:2: segments of two pixels. A flatter line, and one you’ll meet everywhere.
- 1:3: segments of three. Flatter still.
- 1:4, 1:5 and so on: longer segments, flatter lines. The same works vertically: segments of two pixels stacked on top of each other give a steep 2:1 line.
Why do these look so clean? Because the eye can follow a regular rhythm. Every step is the same, so the line reads as a line, not as a series of steps.
The catch: there are only so many of these clean angles. In the same forum thread, the user Olga_Galvanova points out that “fixed ratios only work for limited number of angles”. If you need an angle between 1:2 and 1:3, there’s no perfectly even sequence for it. Another user in the thread, BraidAcer, suggests starting from the shortest equal segments and then spreading the missing pixels as evenly as you can. In practice that means mixing the two segment lengths in a regular pattern, for example 2 3 2 3 2 3, and keeping the pattern consistent along the whole line. A regular rhythm still reads calm. A random one doesn’t.
Practice: draw a 1:1, a 1:2 and a 1:3 line on your canvas, each about 20 pixels long. Count the segments. Every number in each sequence should be the same.
Step 4: Spot Jaggies
A jaggy is a spot where a line or curve suddenly steps the wrong way. The article Anti-Aliasing Fundamentals for Pixel Artists on Pixel Parmesan describes jaggies as “groups of pixels which form particular line patterns”, patterns that don’t represent the intended line or curve well. In practice, it’s a segment that’s longer or shorter than its neighbors, so the line seems to bend or bump at that spot.
You can find jaggies in two ways:
- Count. Write down the segment sequence. A straight line with the sequence
2 2 3 2 2has a jaggy in the middle: the 3 doesn’t belong. - Zoom out. At 800 % zoom, a single long segment looks harmless. At 100 %, it shows up as a kink. If a line looks bent and you can’t say why, zoom out and look again.
One common source of jaggies: the very start of the line. Olga_Galvanova notes in the forum thread that starting a line with a single pixel creates a tiny slope or curve right at that spot. Check both ends of your lines. They’re where the pattern most often breaks.
Step 5: Fix Jaggies by Moving an End Point
Here’s the good news: you rarely have to redraw a broken line pixel by pixel. Most of the time, the line is simply a little too long or too short for a clean ratio, and the leftover pixel ends up somewhere along the line as an odd segment.
In the forum thread, Olga_Galvanova fixes a broken line exactly like this: shift the bottom end up by one pixel and the left end to the left by one pixel, and the line becomes a clean 2:1. In the diagram above, moving one end by a single pixel is enough. The line had eleven pixels of width for five segments, and that leftover pixel created the 3. With ten pixels of width, every segment is a 2.
So when a line won’t come out clean:
- Count the segments and find the odd one.
- Ask which clean ratio you meant. Mostly 2s with one 3? You meant 1:2.
- Move one end point by one pixel so the total width (or height) fits that ratio. Then draw the line again.
- Count again.
In Aseprite, the Line tool (shortcut L, according to the Aseprite drawing docs) makes this quick: undo, move the start or end by one pixel, draw again. Moving an end point shifts your line slightly, but a line that’s one pixel off its target and clean almost always looks better than a line that hits the target and has a jaggy.
Step 6: Draw Curves With Growing and Shrinking Segments
Curves follow the same idea, with one difference: the segment lengths are supposed to change, but gradually. Brandon at Tiny Warrior Games puts it as “gradually increase/decrease the number of pixels” in your line.
Picture a quarter circle. Where the curve is steep, the segments are short. Where it flattens out, they get longer. The Lospec tutorial describes the same for circles: the longest segments go on the top, bottom, left and right, and they get smaller towards the middle between them.
The diagram uses the example from the Aseprite forum thread. Olga_Galvanova writes that if the pattern is 1,1,3,2,4,4, you change it to 1,1,2,3,4,4. The left curve contains all the right segments, just in the wrong order: the 3 comes before the 2, so the curve flattens, gets steeper again for a moment and then flattens again. That’s the bump. On the right, the lengths only grow, and the curve reads smooth.
The Lospec tutorial shows the same mistake on a circle: the sequence 5, 2, 1, 2, 1 makes a lump, while 5, 2, 2, 1, 1 doesn’t.
How to draw a clean curve:
- Sketch the curve roughly, freehand or with Aseprite’s Curve tool (
Shift+Laccording to the drawing docs). - Clean up thickness first, as in Step 2. One pixel, diagonal connections only.
- Count the segments from one end to the other.
- Sort out bumps. Every sequence should rise or fall steadily, like
1 1 2 3 4 4. Where a longer segment sits before a shorter one, move pixels from one row to the next until the order is right. - Check at 100 %.
Don’t take the rule too literally. Olga_Galvanova adds that the shape decides: some bulges are meant to be there. A muscle, a fold in cloth or a dent in a helmet is a bump on purpose. Brandon also notes that real curves occasionally step back. The rule is about avoiding bumps you didn’t intend, not about making every shape perfectly round.
Step 7: Let Aseprite Help (and Know What It Does)
Three Aseprite tools are worth knowing for line work:
- Line (
L) for straight lines. Combine it with the end-point fix from Step 5. - Curve (
Shift+L) for a first curve, which you then clean up by counting segments. - Pixel-perfect for freehand strokes. The Pencil tool’s context bar has a Pixel-perfect option, which the Aseprite context bar docs describe in one sentence: “Enables/disables pixel-perfect strokes.” In an Aseprite forum thread, eishiya adds that this kind of pixel perfection is “only really relevant with 1px-thick lines”. Draw the same freehand curve once with the option on and once with it off, then compare the corners from Step 2.
No tool replaces counting. The Line tool distributes leftover pixels for you, and that’s exactly where jaggies come from. Treat every tool result as a first draft.
Step 8: Check the Result at 100 %
Every line looks different at 800 % than at real size. Olga_Galvanova’s last advice in the forum thread: “check the image in preview window at 100% scale” and try variations until you find what looks best.
Aseprite lists the Preview Window as one of its helpers for drawing. Keep it open next to your zoomed-in canvas while you clean up lines, and you’ll see every change at the size your players will see it. A line that’s clean by the numbers but looks wrong at 100 % is still wrong. Trust the preview over the count.
A word on what comes next: once your lines are clean, you can smooth them further with manual anti-aliasing, placing in-between colors at the steps. Brandon describes this in a separate post on anti-aliasing, and the Pixel Parmesan article stresses that not every style of pixel art needs it. Anti-aliasing smooths a clean line. It can’t rescue a broken one, so fix the segments first.
Common Mistakes
Drawing freehand and leaving it. Freehand lines almost always have extra corner pixels and uneven segments. That’s fine for a sketch. Clean it up before you call it done.
Lines thicker than intended. Extra pixels at the steps make L-shaped corners. Segments should only touch diagonally, unless you want a sharp point on purpose.
Hitting the exact end point at any price. A line that ends exactly where you planned, but with a jaggy in the middle, looks worse than a clean line one pixel off. Move the end point.
Random segment mixes. 2 3 2 2 3 3 2 looks shaky. If you need an angle between two clean ratios, mix them in a regular pattern.
Curves with bumps. A longer segment in front of a shorter one breaks the flow. Sort the lengths so they rise or fall steadily.
Smoothing everything. Not every bump is a mistake. Folds, muscles and dents are bumps on purpose. Count first, then decide.
Checking only zoomed in. Jaggies hide at 800 % and show up at 100 %. Keep a preview at real size open.
Quick Reference
- Thickness: one pixel, segments touch only at the corners
- Straight lines: equal segments,
1 1 1,2 2 2,3 3 3 - In between: mix two lengths in a regular pattern, for example
2 3 2 3 - Jaggy fix: count, find the odd segment, move one end point by a pixel, draw again
- Curves: lengths grow or shrink steadily,
1 1 2 3 4 4, not1 1 3 2 4 4 - Aseprite: Line
L, CurveShift+L, Pixel-perfect in the Pencil context bar, Preview Window at 100 %
What You’ve Learned
- How to read any pixel line as a sequence of segments
- Why lines should be one pixel thick and connect only diagonally
- How to build straight lines from equal segments with the slopes 1:1, 1:2 and 1:3
- How to spot jaggies and fix them by moving a single end point
- How to draw curves whose segments grow and shrink evenly
Next up: take a sprite you’ve already drawn and clean up its outline with the segment count. If it still feels flat afterwards, Pixel Art Shading shows how to give it volume, and Silhouette and Readability helps you check whether the cleaned-up shape still reads at a glance.
Sources
- Aseprite Community: How do I make Straight & Curved Lines properly? (forum thread, August 2021) and Issues with the pencil/brush tool (forum thread, July 2019)
- Tiny Warrior Games: Game Development: Pixel Line-art Cleanup (December 2018) and Pixel Art Anti-Aliasing (December 2018)
- skeddles, Lospec: Pixel Art Outlines Tutorial (April 2016)
- Pixel Parmesan: Anti-Aliasing Fundamentals for Pixel Artists (September 2020)
- Aseprite documentation: Drawing and Context Bar (accessed November 2026)