The SVG minifier runs your SVG files through the SVGO engine to strip editor metadata, comments, and redundant attributes, typically reducing file size by 30–70% while leaving the visual output unchanged. It is most useful for cleaning up files exported from design tools like Illustrator, Figma, or Inkscape before deploying them to a web project.
Where the size savings come from
Design software exports carry a lot of data that browsers never use: layer names, unused style definitions, editor-specific XML namespaces, and floating-point coordinates with six or more decimal places like 23.456789. Removing these has no visible effect on the rendered graphic. The exact savings depend on the source tool — Illustrator exports tend to be bloated with namespace declarations, while Figma exports are usually leaner.
Multi-pass processing
Enabling multi-pass tells SVGO to repeat the optimization cycle until the file size stops decreasing. For files with deep <g> group nesting, multi-pass typically saves an additional 3–10% beyond a single pass. For simple, already-flat icons the difference is negligible. The processing runs in the browser and completes in well under a second even with multi-pass enabled.
Prettify vs. minify
"Prettify code" re-formats the output into indented, readable XML. This is useful when you intend to inspect or hand-edit the SVG afterward. If your goal is the smallest possible file for production deployment, do not enable prettify — the two goals are directly opposed and prettify will add back whitespace that minification just removed.
Options that can break your SVG
Default options are safe for standard icons. These specific settings require caution:
- Clean IDs — renames and removes IDs that appear unused. If external CSS or JavaScript selects SVG elements by ID for animations, turning this off prevents those selectors from breaking.
- Remove script elements / Remove style elements — if the SVG contains embedded animations or interactive behavior driven by
<script>or<style>, enabling these removes the animation entirely. - Remove viewBox — without a
viewBox, the SVG cannot scale responsively. Only safe when fixedwidthandheightattributes are present and scaling is not needed.
All processing runs locally in the browser; files are not uploaded to any server.