Image to SVG Tracer (Posterise and Vectorise)
Drop in a PNG, JPG or WebP and get an SVG made of stacked colour shapes you can scale, recolour and edit.
Use the tool
Why this tool exists
The tracer reduces the image to a small palette (median cut refined by k-means, with anti-aliased edge pixels ignored when the palette is chosen), removes tiny islands, then follows the exact pixel boundary of each colour including holes. The staircase outline is smoothed with a short filter that keeps real corners, simplified with the Douglas-Peucker algorithm and written as straight segments or quadratic curves. Layers are stacked, each colour also covering the ones drawn above it, so no hairline gaps show between neighbours.
With simplification set to 0 the SVG reproduces the quantised bitmap pixel for pixel; this was checked by rendering the SVG with cairosvg (0.00 percent mismatch). With simplification the only differences are along edges, about 1 to 2 percent of pixels on a test logo.
It is for flat artwork. A photograph becomes colour bands, not a faithful vector. It does not fit optimal Bezier curves like Potrace, so diagonal and round edges can look slightly lumpy at high zoom, and thin strokes under about 2 pixels can erode. Images are traced at no more than 1000 pixels on the long side. Everything runs in your browser.
How to use it
- Choose an image file.
- Pick colour layers (try 8) or black and white for a silhouette.
- Raise the simplification for fewer points, or set it to 0 for exact pixel edges.
- Download the SVG and open it in a vector editor to refine it.
Frequently asked questions
Can it convert a photo to SVG?
It will produce a posterised version with a few flat colours. That can look striking, but it is not a faithful vector copy of a photo.
How many colours should I use?
Logos and icons usually need 2 to 8. If a small dark detail such as text turns into a neighbouring colour, add colours.
Why are curves not as smooth as Potrace?
Outlines are smoothed by filtering and midpoint curves rather than optimal curve fitting. For print-quality tracing of a black and white logo, run a larger source image or refine the result in a vector editor.
Does it keep transparency?
Fully transparent areas (alpha below 50 percent) stay empty; partly transparent edge pixels are treated as opaque or empty.
Is my image uploaded?
No. It is decoded and traced locally in your browser.