Free Online SVG Optimizer (SVGO)
Upload an .svg file — we run SVGO preset-default with multipass, strip Inkscape metadata, merge paths, round coordinates. Live preview, copy the code, or download .min.svg.
Lower = smaller file but paths may drift by a few pixels. 3 is a balanced default.
About SVG Optimizer
SVG files exported from Illustrator, Figma, or Inkscape often carry a lot of junk: comments, editor namespaces, auto-generated ids, 10-digit decimal coordinates. SVGO (SVG Optimizer) by Kir Belevich is the standard tool for stripping all of that away without changing the rendered shape.
We use SVGO preset-default with multipass enabled — multiple optimization rounds, each applying 30+ plugins. Decimal precision is adjustable (0-10) to balance size vs. path accuracy. The viewBox is preserved so the SVG stays responsive.
- SVGO preset-default with multipass
- Decimal precision slider (0-10)
- Before/after SVG preview
- Size comparison and % saved
- Copy code or download .min.svg
- viewBox preserved for responsive layouts
How to optimize an SVG
- 1
Upload the SVG
Drop a .svg file into the upload area. Files up to 25MB (huge for SVG).
- 2
Adjust precision
3 is the default. Drop to 1-2 for icons, raise to 5-6 for detail-sensitive graphics.
- 3
Click Optimize
SVGO runs server-side, usually under 1s. Your machine does nothing.
- 4
Compare and download
See before/after sizes and % saved. Copy the code or download the .min.svg.
When to use SVG Optimizer?
SVG before and after SVGO
Real numbers from a 10-icon Figma export — average values after SVGO preset-default + multipass.
| Criterion | Source SVG (Figma/Illustrator) | After SVGO |
|---|---|---|
| Average icon size | 8-15 KB | 1-3 KB (70-85% smaller) |
| Coordinate form | M12.34567891 2.98765432 | M12.3 3 (precision 1-3) |
| Inkscape/Adobe metadata | <sodipodi:namedview> present | Removed |
| Auto-generated ids | id='Path_1234', id='g_567'... | Removed (when unused by CSS) |
| Nested <g> wrappers | Deeply nested | Flattened |
| Duplicate paths | Present | Merged (mergePaths plugin) |
| viewBox preserved | - | ✅ (kept for responsive layouts) |
| Browser rendering | Identical | Identical (pixel-identical) |
How does SVGO work?
SVGO (SVG Optimizer) is Kir Belevich's JavaScript library — the standard SVG optimization tool, used by GitHub (Octicons), VSCode, Iconify, webpack plugins, and countless CI/CD pipelines. The architecture is plugin-based with 50+ plugins, each handling one independent transform.
preset-default includes 35 core plugins: removeMetadata (drops Inkscape/AI namespaces), convertPathData (rounds coordinates, switches to relative), mergePaths (merges same-style paths), convertTransform (collapses transforms), collapseGroups (flattens nested <g>), removeEmptyAttrs, removeUselessDefs, and more. Each plugin saves a few percent; together they typically hit 40-70%.
Multipass mode reruns the whole optimization until no further gains are found — useful because some plugins only unlock after others run. For example, collapseGroups unlocks mergePaths over a group it just flattened. We enable multipass by default at precision=3 (rounds to 0.1 pixel — invisible to the eye).
SVG Optimizer FAQ
Will SVGO break my CSS animations?
Does it handle SVGs with base64 <image> tags?
Does the output visibly differ from the original?
Can I optimize many files at once?
Related tools
Color Vectorize (VTracer)
Convert color PNG/JPG to pure SVG with the VTracer algorithm — preserves gradients and fine detail.
Mono Vectorize (Potrace)
Vectorize logos, icons, and black-and-white line art with Potrace — smooth curves, clean paths, minimal size.
Batch Convert
Upload many images at once, pick a single engine (color or mono), download them all as a ZIP of SVGs.