Use SVG Compressor

Enter your data below to use the SVG Compressor

📌 Try these examples:
RESULT

Last updated

What SVG Compression Does

SVG files exported from design tools like Illustrator, Inkscape, or Figma contain a lot of unnecessary data: editor metadata, empty groups, redundant attributes, default values, and verbose number precision. SVG compression (optimization) removes this bloat without changing the visual output, often reducing file size by 50–80%.

What Gets Removed

CategoryExamples
Editor metadataInkscape/Illustrator namespaces, sodipodi: elements
Comments<!-- Created with... -->
Default valuesfill="black", opacity="1"
Empty elements<g></g>, <defs/>
Unused defsGradients, filters, symbols not referenced
WhitespaceIndentation, newlines between elements
Number precision10.00000010

SVGO Configuration

JavaScript
// svgo.config.js
module.exports = {
  plugins: [
    'removeDoctype',
    'removeXMLProcInst',
    'removeComments',
    'removeMetadata',
    'removeEditorsNSData',
    'cleanupAttrs',
    'mergeStyles',
    'inlineStyles',
    'minifyStyles',
    'cleanupIds',
    'removeUselessDefs',
    'cleanupNumericValues',
    'convertColors',
    'removeUnknownsAndDefaults',
    'removeNonInheritableGroupAttrs',
    'removeUselessStrokeAndFill',
    'removeViewBox',  // set to false if you need responsive SVG
    'mergePaths',
    'convertShapeToPath',
    'collapseGroups',
  ]
};

Frequently Asked Questions

Simply enter your data, click the process button, and get instant results. All processing happens in your browser for maximum privacy and security.