Free SVG to PNG converter
SVG to PNG at the exact size you need
Free to use, no account asked for: hand it up to 20 SVG files, choose a scale factor, a target width or an exact pixel box, and each one is redrawn at that size in your browser. The size is written onto the root element before rasterizing, so a ×4 export carries four times the detail rather than a small bitmap stretched to fit. Transparency survives as an 8-bit alpha channel, or you can flatten onto a color for the mail clients that paint alpha as black.
- 100% free
- No signup
- Up to 20 files
- @2x and @3x
- Alpha channel kept
Drop up to 20 SVG files here, or choose them below. Nothing is uploaded — the rasterizing happens in this tab.
Press Ctrl+V anywhere on the page to drop in SVG markup straight from a code editor — no need to click the field first.
Output size
Background
No file yet. An SVG carries geometry rather than pixels, so the size of the PNG is a decision you make here rather than something read off the file — though the width, height and viewBox on the root element are used as the starting point.
How to convert an SVG to a PNG
Three steps: open the file, decide the pixel size, take the raster.
Open the SVG
Drop up to 20 .svg files onto the panel, choose them from disk, or paste the markup itself — anything starting with <svg or an XML declaration is picked up from the clipboard. Each file is parsed once and its natural size is read off the root element: the width and height attributes first, the viewBox ratio if those are missing, and 300 × 150 if the file declares neither, because that is the size a browser gives a replaced element with no intrinsic dimensions.
Say how big the raster should be
Pick one of three ways to decide: a scale factor applied to the natural size, a target width with the ratio kept, or an exact width and height box for a fixed slot such as a 1200 × 630 social card. The ×1 to ×4 buttons are shortcuts, and “This screen” reads window.devicePixelRatio so the export matches the display you are looking at. Tick the @2x and @3x box to get the whole set in one pass.
Take the PNG
Every result shows its pixel dimensions, its file size and how many milliseconds the render took. Download writes a single file, Copy image puts the bitmap on the clipboard for a paste straight into Figma or a chat window, and Download all fires the whole batch 300 ms apart so the browser does not treat it as a popup flood. Filenames keep the original stem and gain an @2x or @3x suffix when the retina set is on.
Technical specifications
| Accepted input | SVG 1.1 and SVG 2 markup, dropped as .svg files, chosen from disk, or pasted as text; gzip-compressed .svgz is not decompressed |
|---|---|
| Batch size | 20 files per drop, each measured and rendered against its own natural size and aspect ratio |
| Output format | PNG, 8 bits per channel with a full alpha channel, non-interlaced — the only thing a canvas writes, and the reason the quality argument is ignored |
| Size modes | Scale ×0.1 to ×40, target width with the ratio kept, or an exact width × height box; a button reads window.devicePixelRatio for the current screen |
| Natural size resolved from | The width and height attributes, then the viewBox ratio, then 300 × 150 — the CSS default for a replaced element with no intrinsic size |
| Maximum output | 8,192 px per side and 16.7 megapixels in total; past that iOS Safari returns a blank canvas rather than an error |
| Background | Alpha preserved by default, or flattened onto any CSS color — hex, rgb(), hsl() or one of the 148 keywords |
| Not rendered | Anything needing the network — external bitmaps, webfonts, external filters — is dropped without a warning; a data URI is not a fetch and does render; a foreignObject taints the canvas and stops the export outright |
Frequently asked questions
What pixel size should I export at?
Export at the size the image occupies on screen multiplied by the pixel ratio of the densest display you care about, which in practice means ×2 for a laptop and ×3 for a phone. A 48 px icon shipped at 48 px looks soft on every device made since 2014; the same icon at 144 px looks correct everywhere and still costs a few kilobytes. Where the slot is fixed rather than fluid — an email header, an app-store screenshot, an Open Graph card — use the exact box mode and type the two numbers the specification gives you.
Why is the text in my PNG set in the wrong typeface?
Because an SVG rendered through an image element cannot fetch a font. The renderer has no network access at all in that mode, so an @font-face rule pointing at a .woff2 file silently fails and the text falls back to a generic system family, usually with different metrics that shift the layout as well as the shapes. The fix is to convert the type to outlines before exporting: Type › Create Outlines in Illustrator, Flatten in Figma, Path › Object to Path in Inkscape. Embedding the font as a base64 data URI inside the SVG also works and costs 30-60 kB per weight.
My SVG has no width or height attribute — what size does it become?
It takes the viewBox as its aspect ratio and this page shows you which rule was used for each file. A viewBox of 0 0 24 24 gives a 24 × 24 natural size, so a ×10 factor writes 240 × 240. When both the attributes and the viewBox are missing there is no ratio to work from, and the fallback is the 300 × 150 default that CSS gives any replaced element without intrinsic dimensions — pick the exact box mode in that case rather than trusting the number.
Part of my drawing is missing from the PNG, and nothing warned me.
An image element pointing at a URL is the usual culprit: the sandbox has no network, so the bitmap never arrives, the renderer draws everything else and reports no error at all. Inlining that asset as a base64 data URI fixes it, because a data URI is not a fetch and does render. The related failure is louder — a file containing a foreignObject taints the canvas in Chrome and Safari even when the content inside it is local, and the export stops with a security error rather than a hole in the picture. Both cases are worth checking before you conclude the converter is at fault: open the file and search it for href="http and for foreignObject.
Why PNG rather than JPEG or WebP?
Because the input almost always has transparency and JPEG has no alpha channel at all. PNG written by a canvas is 8 bits per channel with a full alpha channel, lossless, and non-interlaced; the quality argument that JPEG and WebP accept is ignored for it entirely. When you do need an opaque file — an email client that paints alpha as black, a print workflow that rejects transparency — flatten onto a background color here first, and the result composites correctly instead of leaving grey fringes around the edges.
Can I convert a folder of icons in one go?
Yes — drop up to 20 files at once and each is measured and rendered on its own natural size. In scale mode a 24 px icon and a 512 px illustration both come out at their own dimensions times the factor, which is what you want for an icon set; in width mode they are all normalized to the same width instead. The 20-file ceiling is there because every render holds a full-size canvas in memory for a moment, and a batch of 8192 px exports would otherwise exhaust the tab.
Do the colors shift during rasterization?
No — the values in the SVG are written into the PNG unchanged, since both are interpreted as sRGB and no color management step runs in between. What can shift is anything the file expected the page around it to supply: currentColor resolves to black, a CSS custom property defined outside the file resolves to nothing, and a class styled by your stylesheet is unstyled here. An SVG loaded as an image is a self-contained document, so every value it uses has to be inside it.
About rasterizing vectors
An SVG has no pixels in it, so converting one is less a conversion than a decision: somebody has to say how many pixels the drawing should become. Browsers answer that question with a small cascade — the width and height attributes on the root element first, the viewBox ratio if those are absent, and failing both a flat 300 × 150, which is what CSS hands any replaced element that declines to declare a size. That last rule is why an icon exported straight out of a design tool sometimes lands as a squat rectangle in a converter: the file never said how big it was, and 300 × 150 is the specified shrug.
The step most converters get wrong is the drawing itself. Handing a canvas a destination rectangle is allowed to rasterize the vector once at its natural size and then resample the result, which is exactly how a ×4 export comes back with soft edges and blurred hairlines. This page rewrites the width and height on the root element to the target first, keeping a viewBox so the geometry still maps, and only then draws — one rasterization, at full size, with the curves recomputed. The other thing worth knowing is that an SVG loaded through an image element runs in a sandbox with no network and no script: external bitmaps and webfonts are dropped in silence, currentColor resolves to black because there is nothing above it to inherit from, and a foreignObject taints the canvas so hard that the export stops rather than merely losing that element. Cleaning the file up with the SVG optimizer before you rasterize makes those dependencies obvious, and if you are working in the other direction — tracing a bitmap into paths — that is a genuinely different operation, not this one reversed.
Most of the PNGs that come out of here are going somewhere specific. Browser tabs and home screens want a fixed ladder of sizes, which the favicon generator lays out and the ICO converter packs into one file for Windows. Social previews are a single hard-coded box — 1200 × 630 — which is why the exact-size mode starts there and why the OG image generator composes at the same dimensions. Frame-by-frame animation needs every cell at identical pixel dimensions before the spritesheet generator can pack them, and a layout that just needs a grey box of known size is better served by the placeholder image generator than by exporting one.
Where your SVG is rendered
Every number on this page is worked out by JavaScript running in the tab you are reading it in. Nothing you type, paste or open is uploaded, logged or kept, which is also why the tools carry on working after you disconnect from the network.
Each file is turned into a blob: URL that exists only inside this tab, drawn once into a canvas, and revoked as soon as the PNG bytes exist. Because the renderer has no network access, an SVG that tries to phone home for a font or a bitmap fails quietly here rather than reporting your visit to a third party.