Optimize

SVG optimizer

Make SVG icons, logos and illustrations smaller and cleaner for websites and apps, and remove anything that could run code, without changing how they look.

Compared before you download

Each optimised SVG is drawn next to the original and compared pixel by pixel. If the normal settings would change the look, careful settings are used instead.

Ready. SVGs are cleaned on this device and never uploaded.
Add SVG filesFrom Illustrator, Inkscape, Figma or anywhere else. Up to 100 files of 10 MB.
Or paste SVG code

Settings

Always removed: scripts, event handlers, links that run code, editor data and metadata.

Files

Optimised files appear here, with their savings.

    How it works

    Add, optimise, download

    1. Add SVG files or paste code. Up to 100 files at once.
    2. Leave the settings or adjust them. Automatic precision suits most files; titles stay for screen readers unless you remove them.
    3. Check the result. See each file before and after, its new size and its size when your server compresses it.
    4. Download or copy. Single files, a ZIP, or the code to paste straight into HTML.

    What is removed

    Weight that does not draw anything

    • Editor data from Inkscape, Illustrator, Sketch and Figma: layers, guides, zoom levels and private namespaces.
    • Metadata and comments, except comments starting with <!--!, which are kept for licence notices.
    • Unused IDs and definitions, such as gradients nothing uses, and empty or plain groups.
    • Long decimals, rounded to what the drawing's size needs, with path data written compactly.

    Safety

    SVGs that cannot run code

    An SVG is a document, and it can contain scripts, event handlers and links that run code when opened directly in a browser. The optimiser always removes scripts, on… attributes, links to javascript: and similar addresses, embedded HTML and animations that rewrite links. Files that declare XML entities, a trick used to freeze computers, are refused. Previews here are drawn as images, so nothing in a file can run.

    FAQ

    Questions about SVG optimisation.

    How much smaller will my SVG get?

    Files exported from design tools often shrink by half or more, because they carry editor data, metadata and long decimals. Hand-written or already optimised SVGs change less. Every file shows its old and new size, and its size after gzip.

    Will my SVG still look the same?

    Yes. Each result is drawn next to the original and compared. If the normal settings change the look, the tool uses careful settings automatically, and it tells you if a file still differs.

    Is it safe to put an SVG on my website?

    An SVG can contain scripts that run when it is opened on its own. This tool removes scripts, event handlers and code links from every file, which makes SVGs from other people much safer to publish.

    Why keep titles and descriptions?

    Screen readers read an SVG's title and description to blind and partially sighted visitors. They are small, so they are kept unless you choose to remove them.

    What does automatic precision mean?

    Coordinates are rounded to as many decimals as the drawing's size needs: two for a 200-unit drawing, three for a 24-unit icon, more for very small drawings. That keeps shapes in place while removing digits nobody can see.

    Are my files uploaded?

    No. SVGs are read, cleaned and compared in your browser. Your files and code never leave your device.