SVG Optimizer

Clean and minify SVG files by removing unused elements and collapsing whitespace.

Or upload an SVG file

Drop .svg file here or click to browse

Optimization options

Use 3 or more for icons with a small viewBox (for example 0 0 1 1).

Paste SVG code or upload a file to get started.

About This Tool

How to Use
  1. Paste your SVG code into the text area or upload an .svg file
  2. Select which optimizations to apply and how many decimal places to keep
  3. Click Optimize SVG (later option changes apply at once)
  4. Review the before/after previews and size savings
  5. Copy the optimized SVG or download it as a file
Common Use Cases
  • Reducing SVG file size before bundling into a web app
  • Cleaning up SVGs exported from Figma or Illustrator
  • Removing editor metadata before committing icons to a repository
  • Minifying inline SVGs used in CSS or HTML
Tips & Tricks
  • Remove titles and descriptions only if you don't need accessibility labels
  • 2 decimal places is visually lossless for most icons; use 3 or 4 for icons with a tiny viewBox
  • Editor data from Inkscape and Illustrator (inkscape:, sodipodi:, data-name) is often a large part of an exported file
  • Always preview the result to confirm the visual output is unchanged

Related Tools