Skip to content

SVG to PNG Converter

Paste SVG markup or drop an .svg file, set an output width (or leave it to the SVG's own size), and download a PNG — rendered by the browser's own SVG engine on a canvas, so it looks exactly like the SVG would rendered on a page, not a re-interpretation by a separate rasterizer.

  • Paste SVG code or drop an .svg file
  • Reads intrinsic size from width/height or viewBox
  • Optional transparent or white background
  • Rendered by the browser's real SVG engine, not a separate parser
  • Runs fully client-side

Converter

Rendered locally, nothing uploaded

How to convert SVG to PNG

  1. 01

    Paste SVG code or drop a file

    Either works — dropping a file loads its text into the same box.

  2. 02

    Set an output width, if needed

    Leave it blank to use the SVG's own intrinsic size.

  3. 03

    Download the PNG

    Rendered at the requested size, ready to use anywhere a raster image is needed.

Why this uses the browser's own SVG renderer#

SVG is a genuinely complex format — gradients, filters, clipping paths, embedded fonts, nested transforms — and a from-scratch SVG-to-raster implementation would inevitably render some of that incorrectly or not at all. Instead, this tool loads the SVG as a real <img> element, which every browser already renders using its full, standards-compliant SVG engine — the exact same code path that draws an SVG placed directly on a web page — then draws that rendered image onto a canvas and reads the pixels back out as a PNG. The output matches what the SVG would look like on a real page, because that is literally how it was rendered.

Where the output size comes from#

An SVG can declare its size explicitly with width/height attributes on the root <svg> element, or implicitly through its viewBox, which also defines the aspect ratio used for scaling. This tool reads whichever is present to determine a sensible default output size, and lets you override the width — the height then scales automatically to preserve the original aspect ratio, unless a percentage-based width/height forces a fallback to viewBox.

Transparent by default, because that is what SVG actually is#

An SVG with no background shape is transparent by nature — there is no implied white canvas underneath it, the same way a PNG or a piece of glass has no default color. This tool preserves that transparency by default, since assuming a white background would silently change what the graphic actually contains. A white-background option is available for cases where the destination genuinely needs an opaque image, like a JPEG-only upload target.

Frequently asked questions

Why not build a custom SVG renderer instead of using the browser's?

SVG supports gradients, filters, clipping paths and more — a from-scratch renderer would inevitably get some of that wrong. Using the browser's own SVG engine, the same one that renders SVG directly on a web page, guarantees the PNG matches what the SVG actually looks like.

Where does the default output size come from?

From the SVG's own width/height attributes, or its viewBox if those are missing or percentage-based. You can override the width and the height scales automatically to preserve the aspect ratio.

Why is the background transparent instead of white by default?

Because an SVG with no background shape is transparent by nature — assuming white would change what the graphic actually contains. A white-background option exists for destinations that specifically need an opaque image.

Is my SVG uploaded anywhere?

No. Rendering happens entirely in your browser using canvas — nothing is sent to a server.

Developers

UUID Generator

Generate cryptographically random UUID v4 or time-ordered UUID v7, in bulk.

Developers

Base64 Encoder & Decoder

Encode and decode Base64 with correct UTF-8 handling, including the URL-safe alphabet.

Developers

ULID Generator

Generate ULIDs — sortable by creation time like UUID v7, but Crockford Base32 instead of hex.