SVG viewer and preview

Paste SVG code or open an .svg file and see it rendered as you type, with its size and viewBox. Save it as a PNG or JPG when you need an image.

SVG code

Paste SVG markup (must contain an <svg> element) or upload a file up to 500 KB. Your code stays in your browser and is never sent to a server.

Preview

Your SVG will appear here once you paste or upload code.

PNG preserves transparency. JPEG uses a white background. Clipboard copy is PNG.

Guides · Transparent PNGs from SVG · SVG code to JPG · SVG code to SVG file · SVG to JPG

Features

What the SVG viewer can do

Preview

  • Live preview

    The SVG redraws as you type. Errors show next to the code.

  • Size and viewBox

    See the declared width and height, the viewBox, and the file size.

  • Export size

    The final image size in pixels is shown before you download.

Input

  • Paste or upload

    Paste SVG markup, or open an .svg file up to 500 KB.

  • Formatting

    Pasted and uploaded markup is tidied with Prettier so it is easy to read and edit.

  • Code editor

    Edit the markup with syntax highlighting and line numbers. Clear starts over.

  • Scripts removed

    Scripts, event handlers and foreignObject are stripped before the SVG is drawn.

Export

  • Free sizes

    500, 1000, 1500 or 2000 px on the longest edge. The aspect ratio is kept.

  • PNG

    Keeps the transparent background.

  • JPG

    Drawn on a white background, for forms and apps that want JPG.

  • Copy PNG

    Put the PNG on the clipboard to paste into a doc or chat.

  • SVG file

    Save the markup as an .svg file.

  • Larger sizes Pro

    3000 or 4000 px, or any custom size from 100 to 8000 px.

  • WebP Pro

    A smaller file than PNG for the web, with transparency.

  • Batch to ZIP Pro

    Convert up to 50 .svg files at once into one ZIP of PNGs. File names are kept.

How to view an SVG online

  1. 01

    Paste or open an SVG

    Paste SVG markup, or upload an .svg file up to 500 KB.

  2. 02

    See it rendered

    The preview updates as you type, with the size, viewBox, and file size underneath. Scripts and other unsafe elements are removed first.

  3. 03

    Save it if you need to

    Download a PNG or JPG at 500 to 2000 px on the longest edge, or save the markup as an .svg file.

Need to make your code look great too?

Paste code, pick a theme, and download a PNG with syntax highlighting.

Open Code to image

Also need to convert HTML code?

Turn any HTML markup into a PNG or JPEG.

HTML code to image converter

FAQ

Questions

Everything you need to know about the SVG viewer.