SVG Preview & Optimizer

Paste SVG code or open a file to see it rendered, then remove the clutter design tools leave behind — comments, editor namespaces, metadata and redundant whitespace.

Choose an SVG file (optional)
Original
Optimized

Runs entirely in your browser. Your input and files are not uploaded to any server.

How to use

  1. Paste SVG markup or choose an .svg file.
  2. Select the clean-up options. Number rounding gives the biggest savings but can shift tiny details.
  3. Compare the preview and the size saving.
  4. Copy the optimised code or download it.

Examples

Icon exported from a design tool

Removing editor metadata and whitespace often cuts 30–60% from exported icons.

Inline SVG for a web page

Enable “Remove XML declaration” — it is not needed when the SVG is inlined in HTML.

Privacy

Your files and text stay in your browser while you use this tool, and ads or anonymous visit statistics do not receive them. Only your favorites and recent tools are saved on your device. Privacy policy

Want proof? Check it with your browser’s Network tab: How to check that a tool does not upload your files

Frequently asked questions

Is the preview safe for untrusted SVGs?

The preview is rendered as an image, which prevents scripts inside the SVG from running.

How does this compare to SVGO?

This is a lighter, conservative clean-up. SVGO performs deeper path optimisations; use it in a build pipeline if you need maximum compression.

Related tools

All Image Tools
Favicon GeneratorGenerate a complete favicon set from an image or a letter: favicon.ico, 16–512 px PNGs, Apple touch icon, web manifest and HTML tags, in one ZIP.
Image CompressorCompress JPG, PNG and WebP images in your browser by quality or to a target size such as 100 KB.
Image ResizerResize JPG, PNG and WebP images to exact pixel dimensions or a percentage, with optional aspect-ratio lock.
Search tools