SVG Minifier
Shrink SVG markup with SVGO — no signup, nothing leaves your browser.
This free online SVG minifier strips comments, metadata, and excess path precision from your SVG markup using SVGO's optimizer. Paste markup or upload a .svg file, tune a couple of options, and copy the minified result.
Upload SVG file
Remove comments
Remove metadata & titles
Strips <title>, <desc>, and <metadata> elements. Turn off if you rely on <title> for accessibility.
Path precision
Lower values round coordinates more aggressively for smaller files.
Why minify SVGs
SVG files exported from design tools like Illustrator, Figma, or Sketch usually carry a lot of dead weight: XML comments, editor-specific metadata, unused id attributes, and path coordinates with far more decimal precision than any screen can render. None of that affects how the SVG looks — it just adds bytes. Minifying an SVG removes this cruft, which means smaller page weight, faster downloads, and less data parsed by the browser before the icon or illustration paints.
This is especially worth doing for SVGs used repeatedly across a site — icon sprites, logos, inline illustrations — since the savings compound across every page that loads them.
What SVGO's preset-default optimizes
This tool runs SVGO, the standard SVG optimizer most build tools and design software use under the hood. Its default preset removes comments and XML declarations, collapses redundant whitespace, merges paths where safe, drops empty or unused groups and attributes, and rounds numeric precision in path data and coordinates — all while preserving the rendered output.
Frequently asked questions
Related tools: SVG Viewer · SVG to PNG · SVG Background Remover