Skip to content

image guide

Converting SVG to PNG and PNG to SVG — the Complete Decision Guide

SVG and PNG are different species: one is a set of drawing instructions, the other a grid of finished pixels. Most conversion confusion comes from treating them as interchangeable — converting at the wrong stage, or expecting a PNG to become a scalable file again by wishing. This guide covers both directions honestly: rasterising SVG to PNG at exact pixel sizes with transparency, and the much more limited reality of turning PNG into SVG.

Updated September 22, 2026 · 12 questions answered

Key takeaways

  • SVG → PNG is a render, not a conversion: at export time you choose the exact pixel size, and the result is as sharp as that size — there is no quality loss because vectors have no resolution to lose.
  • Export SVG at 1× display size plus a 2× copy for retina; a single small raster is the mistake that makes crisp vectors look blurry on modern screens.
  • PNG → SVG is tracing, and tracing only works for simple flat graphics: logos yes, photographs never — no algorithm rebuilds a million-colour photo as shapes.
  • Keep SVG as the source of truth for icons and logos; rasterise only at the last step before a raster-only destination.
  • SVG favicons and email have real limits — rasterising to PNG (and a Base64 inline for email) is often exactly why the conversion exists.

Why You Convert SVG to PNG (the Real List)

SVGs lose in a surprising number of 2026 destinations: email clients (most strip or block SVG in HTML mail), PowerPoint's older engines, some CMS media pickers, marketplaces whose upload forms list PNG/JPG only, Android drawable pipelines wanting PNG at fixed densities, and every non-technical colleague whose viewer shows a wall of XML text instead of a picture. The conversion is usually one of these: a form rejection, an email need, or a raster-only pipeline.

And the opposite reason to convert: finality. A delivered PNG cannot be accidentally recoloured or edited by the downstream consumer the way an SVG's open source can. For brand assets handed outside the team, that locked quality is sometimes the feature.

Getting the Raster Size Right

Because the SVG has no inherent pixel size, the SVG to PNG conversion asks you for one — and this is the whole craft. The rule: export at the largest size the raster will ever be displayed at, times two for retina density. A logo that appears 320 px wide in a header gets a 640 px PNG; an icon that lives at 24 px gets a 48. One size up from display is the difference between 'crisp' and 'soft' on every modern screen.

The common failure is exporting at the SVG's nominal viewBox numbers — often 24×24 or 512×512 arbitrary units — and discovering the 24-unit export is a postage stamp. Decide the pixel destination, not the source numbers. Most SVG tooling exports one size at a time; for the multi-density set (1×, 2×, and a print-reserve 512), run a batch of exports with the sizes written down.

Transparency and Backgrounds

PNG carries alpha, so an SVG with no background rect renders to a transparent PNG — exactly right for logos and overlays on varied backgrounds. When the destination wants a matte (a JPG conversion, a PowerPoint slide, an email), set the background in the SVG itself before exporting or accept the flatten colour from the converter; do not try to add the background afterwards by re-saving a transparent PNG over white through a chain of tools, because every extra step is bytes and generations for nothing.

SVG → JPG specifically: the raster becomes JPEG, so the alpha is flattened at that moment. It is a fine format for a matte-backed hero graphic and a poor one for anything with text or sharp edges — JPG's chroma tricks smear vector-clean lines, and the whole point of the SVG was those clean lines. PNG in almost every case.

PNG to SVG: The Honest Version

The reverse conversion is tracing: software looks at raster shapes and guesses the paths that could have drawn them. On flat graphics with solid colours — a logo, an icon, lettering — modern tracing does a genuinely good job, and PNG to SVG tracing is the rescue path for the brand asset whose original vector was never archived. The output needs cleanup (tracing produces excess anchor points), and colour-count discipline helps: flatten a 256-colour mess to 6 solid colours and the trace becomes almost perfect.

On photographs, tracing fails in a way no product page admits: a million-colour image with gradients and noise is not shapes, and the SVG that 'results' is either a bitmap pasted inside an SVG tag (a format shell around the same pixels — zero scalability gained) or a painting-abstract of blotches. If the asset is photographic, the right vector is a source file you do not have; nothing converts pixels into drawing instructions.

Keeping the Chain Clean

The workflow that prevents the whole problem: treat SVG as the master for every logo, icon and flat graphic; keep one canonical folder of them; rasterise on demand for each destination at that destination's size. Every conversion out of SVG is lossless-by-definition (the render is computed fresh), so exports can be regenerated forever; every re-export from a PNG inherits its resolution limit. The moment a raster of a logo is edited and made the source, the chain has quietly downgraded.

And a note on favicons — the most common SVG→PNG conversion request there is, with a twist: modern browsers accept SVG favicons directly, but the legacy ICO and apple-touch slots need rasters at their fixed small sizes, so the favicon workflow ends in exactly this converter, paired with the favicon generator. One square SVG master, a handful of PNG exports, done.

Frequently asked questions

The questions people ask most about svg to png (and back): when to rasterise and when not to, answered directly.

How do I convert SVG to PNG?

Open a browser SVG-to-PNG converter, set the exact output size in pixels, and download — optionally with a transparent background. The vector is rendered at your requested resolution, so the PNG is as sharp as the size you chose. No upload, no install.

What size should I export an SVG to PNG?

Larger than the biggest display size, ideally 2× for retina: header logo shown at 320 px wide → export 640; an icon at 24 → 48. The SVG's viewBox numbers are internal units, not pixels — deciding from those is why exports come out postage-stamp sized.

Does converting SVG to PNG lose quality?

No — a render is not a resample. The vector instructions are drawn fresh at exactly the pixel grid you asked for, and every pixel is mathematically placed. Quality only appears lost later, when someone enlarges the raster beyond the resolution you chose; that is a PNG limitation, not a conversion defect.

Can I convert PNG to SVG and scale it infinitely?

For flat graphics and simple logos, yes — tracing reconstructs paths that scale cleanly, with some cleanup work. For photographs, no: any 'photo to SVG' result either embeds the same pixels inside an SVG wrapper (no scalability gained) or replaces the image with colour blotches. Vectors describe shapes; photos are not shapes.

Why does my PNG look blurry when the SVG was crisp?

Because the PNG was rendered at a small size and then displayed or enlarged beyond it. Re-export the PNG at double the intended display width and the crispness returns — the vectors were never the problem; the raster resolution you froze them at was.

Should I use SVG or PNG for a logo?

SVG as the master everywhere — tiny, infinitely scalable, editable. PNG for every destination that rejects SVG: email, old office software, some site builders, most social avatars (rasterised at the platform's exact display size ×2).

Does SVG to PNG keep transparency?

Yes — the render produces alpha where the SVG has no painted background. If the output came with a white box behind it, the SVG itself contains a background rectangle, or the converter defaulted to white; remove the rect or switch the matte to transparent.

Can email clients display SVG images?

Most cannot — Apple Mail strips SVG in message HTML, Outlook never renders it, and the safe formats remain PNG and JPG. For email, rasterise the SVG to a PNG at 2× display size, or inline it as a Base64 data URI where image-blocking is the concern.

Why do designers ask for SVG files?

Because SVG is the editable, resolution-free source: a developer can recolour it with CSS, scale it for any screen, and embed it anywhere without quality math. A PNG of a logo is a frozen answer; the SVG is the thing itself.

Can I batch convert many SVGs to PNGs?

Yes — drop the whole set on a batch converter and export them all at one chosen size. For scripted pipelines with per-file sizes, a desktop tool like Inkscape in command-line mode (inkscape file.svg --export-width=640) runs over a folder; browser batches cover the interactive case with no setup.

Is SVG good for favicons now?

Yes with a fallback: <link rel="icon" type="image/svg+xml"> is crisp in Chromium and Firefox, but Safari still wants the raster route, and the legacy /favicon.ico request needs a real ICO file. The complete favicon set is SVG plus PNG sizes plus one ICO — which is exactly why the converter exists.

Do converted PNGs carry the SVG's colours exactly?

Yes for normal SVG colours — the rasteriser renders sRGB values to sRGB pixels. The two places people see mismatch: SVG features the renderer partially supports (old filters, some gradients in exotic syntax) and colour-managed print pipelines where the SVG's declared profile disagrees with the render assumption.