Nevquo Pixel › Optimize SVG
SVG files exported from Inkscape, Illustrator and similar tools are full of editor settings, comments and long decimal numbers. This page strips what a browser never needs, and does it carefully so the drawing renders the same.
How to optimize an SVG
- Add your SVG files. Drop one or a whole folder of icons.
- Read the result. Each row shows the old and new size. If a file is already clean, it is kept as it is.
- Download. The file name stays the same, so you can drop the cleaned file over the old one.
What gets removed
The optimizer is conservative. It removes XML declarations and doctype lines, comments, metadata blocks, editor-specific elements and attributes from Inkscape and Sodipodi, empty title and description tags, data attributes, and the whitespace between tags. It also shortens very long decimal numbers inside path data to three digits after the decimal point, which is far below what the eye can see at normal sizes.
It does not rewrite shapes, merge paths, convert units, rename ids or remove anything that could change how the image looks. The trade-off is that savings are smaller than aggressive tools can reach. In return, you can use the result without checking it shape by shape.
A safety check on scripts
An SVG is not just a picture. It can contain scripts and event handlers that run when the file is opened in a browser. When the page sees a script tag, an inline event handler, a foreignObject element or a javascript: link, it warns you on that row. The element is kept, because removing active content is a decision for the author, but you should review it before you publish a file from an unknown source.
Using SVG on a website
SVG is the right format for logos, icons and simple illustrations, because it stays sharp at every size. It is the wrong format for photographs. If your file is a logo that someone only gave you as a PNG, converting it will not create a vector. For raster images use Compress PNG. Also remember that compression on your web server, such as gzip or Brotli, shrinks SVG a great deal on top of what you save here.
A real before and after
We ran an SVG badge exactly as an editor exports it, with metadata, editor attributes and long decimals, through this page.
| File | Before | After | Saved | Visual score |
|---|---|---|---|---|
| badge.svg | 1.9 KB SVG | 615 B SVG | −68% | 100.0 |
The badge.svg test file was drawn by us for this test. Measured with the Nevquo Pixel engine, version 1.2.0, on 2026-10-10. Check it yourself: badge.svg (original). Results (badge.svg).
Frequently asked questions
Will the SVG look exactly the same?
The optimizer only removes data that does not affect rendering and trims decimals to three places. It is designed to leave the picture looking the same.
Why is the saving small compared with other SVG tools?
This one is cautious on purpose. It never merges, rewrites or reorders shapes, so there is no risk of a changed drawing.
Does it remove scripts from the SVG?
No. It warns you about scripts and event handlers but leaves them in place so you can decide.
Can I optimize many SVGs at once?
Yes. There is no limit and you can download a ZIP.
Are my SVG files uploaded?
No. The text is cleaned inside your browser.