How to use the Line Art Extractor
- Open a sketch or photo. Drop the file onto the box, paste a screenshot with Ctrl+V, or click to browse. The two samples — a pencil sketch with a phone shadow and a shaded still life — show each method at its best.
- Choose a method. Pencil scan is for graphite or ballpoint on paper. Ink lines draws bold contours from photos, renders and paintings. Edges traces every sharp change in brightness.
- Dial it in. Detail decides how fine a stroke counts as a line, Contrast how hard its edges are, Noise removal how big a dot must be to survive, and Line weight thickens everything after the fact. In Ink mode, Solid blacks fills the darkest shadows like a brush pen.
- Check before and after. Drag across the image or use the Compare with original slider to see the lines against the source.
- Export. Pick a Line color and Background — Transparent to color underneath, White for printing — then Download PNG for a full-size file or Copy image to paste straight into your drawing app.
Why one threshold can’t clean a phone photo of a sketch
The obvious way to pull lines out of a sketch is a threshold: everything darker than some gray becomes black, everything lighter becomes white. It works on a flatbed scan. It falls apart on a photo taken at your desk, because the paper is never one brightness.
Say the paper reads 230 out of 255 by the window and 140 in the shadow of your phone, while a light pencil line reads 170 on the bright side. Set the cut-off at 160 and the shadowed corner turns into a black blob while the faint line vanishes. Move it to 180 and the line comes back, along with half the shadow. No single number wins.
Pencil scan avoids the problem by asking a local question instead: is this pixel darker than its own neighborhood? At the default Detail of 5, each pixel is compared with the average of a window 47 px across on the preview. Paper in shadow is dark, but so is the paper around it, so it stays white; a pencil stroke is darker than the paper right next to it, so it becomes a line. Lower Detail widens the window (75 px at 1) to bridge heavy hatching; higher Detail narrows it (13 px at 10) to catch fine textures.
Ink lines uses the extended difference of Gaussians (XDoG) described by Winnemöller, Kyprianidis and Olsen in 2012. The image is blurred twice, the second blur 1.6 times wider than the first — the ratio Marr and Hildreth recommended as a close stand-in for the Laplacian-of-Gaussian edge detector. Wherever the narrow blur is darker than the wide one, you are on the dark side of an edge, and that strip becomes ink. At Detail 5 the narrow blur has a radius (sigma) of about 1.45 px on the preview.
Edges is the classic Sobel operator: two 3 × 3 kernels weighted 1-2-1 measure how fast brightness changes horizontally and vertically. It finds outlines everywhere, including in flat color art where the other methods see nothing dark to keep.
Which method fits which drawing
| What you have | Method | Settings to try |
|---|---|---|
| Pencil sketch, phone photo with shadows | Pencil scan | Detail 4–6, Noise removal medium |
| Clean flatbed scan of inks | Pencil scan | Detail 7–8, Contrast 8–10 |
| Photo of a person or building for tracing | Ink lines | Detail 3–5, Solid blacks off |
| Moody photo for a comic panel | Ink lines | Detail 5, Solid blacks 3–5 |
| Flat digital art or a logo | Edges | Detail 7, Line weight +1 px |
| Grainy or heavily textured paper | Pencil scan | Detail 3, Noise removal strong |
Noise removal deletes connected dots smaller than 6, 14, 30, 60, 120 or 240 preview pixels, from light to max. The preview runs on a copy up to 1,100 px on its long side for instant feedback; the download repeats the same math on the full image, up to 4,000 px on the long side, with every radius scaled to match. Everything happens on your own device, so unpublished sketches stay private.
Tips from practice
Shoot flat, not bright. Daylight from a window without the flash gives softer shadows than an overhead lamp. Hold the phone parallel to the page — perspective distortion survives every filter.
Darken faint construction lines with Contrast, not Line weight. Weight thickens everything, including the strokes you meant to keep delicate. Raise Contrast first; add weight only if the whole drawing reads too thin at the final size.
Make the lines a reference layer. In Procreate, open the line layer’s options and turn on Reference; ColorDrop on any other layer then fills up to those lines. Clip Studio Paint has the same idea as Set as reference layer. A transparent PNG makes this a one-step setup.
Pick a line color that matches the finish. A dark brown such as #3B2A20 reads softer than pure black under watercolor-style coloring. To ink by hand over a printout, set the lines to non-photo blue, #A4DDED — the pencil color old reprographic cameras couldn’t see.
Vectorize afterwards if you need to scale. For logos, stickers or cutting machines, run the white-background PNG through the SVG to PNG & PNG to SVG Converter. Want flat color fills instead of lines? Try the Image Posterize Tool.