What It Never Touches
An optimiser that breaks a file is worse than a large file. These are the limits built into this one.
- Ids that something references. Clip paths, masks, gradients, filters and animations all point at ids, and stylesheets select them. Anything referenced is kept; only ids with no reference anywhere are removed.
-
Stylesheet and CDATA content. The body of a
styleelement is copied through untouched, so media queries, selectors and whitespace that matters survive. -
Text a screen reader would read. A
titleordescelement with content in it is kept. Removing it to save 40 bytes is a bad trade. Only empty ones go. -
The drawing itself. No element is restructured, no path is rewritten, and
the
viewBoxis not rounded — that would move the coordinate system under the artwork.
If the file is malformed — a tag that never closes — the tool refuses it rather than guessing. An optimiser that silently repairs a broken file produces a document that differs from the one you started with, and that is the one thing it must never do.
When there is nothing to remove
An SVG that was already minified has nothing left to strip. The tool says so and reports the real numbers, which may be zero — or even slightly negative, because the output is re-serialised. Keeping the original is the better choice in that case, and the result tells you that instead of claiming a saving.
SVG and server compression
Most servers gzip SVG on the way out, which is separate from this: gzip shrinks the transfer, while optimising shrinks the file that is stored, copied, committed and served from a CDN. Doing both is normal. This tool also deflates SVG entries when you save a batch as a ZIP.