Free SVG to PNG Converter
Convert SVG files or pasted code to PNG, JPG or WebP at any scale or exact size, with a transparent or coloured background and batch ZIP download.
Loading tool…
How to convert SVG to PNG, JPG or WebP at any size
Many apps, social networks, office documents and email clients cannot show SVG, so you need a PNG or JPG copy. Because SVG is a vector format, you can render it at any resolution without blur. This converter reads the SVG's own width, height and viewBox, cleans the markup with DOMPurify so scripts and external resources are removed, and lets your browser draw it at the size you choose.
- Add one or more .svg files, or paste SVG code and select Add pasted SVG.
- Check the intrinsic size shown for each file, which is read from its width, height and viewBox.
- Choose the output size: a scale such as 2× or 4×, a width or height that keeps the proportions, or an exact width and height.
- Pick PNG, JPG or WebP, set the quality for JPG and WebP, and choose a transparent or coloured background.
- Select Convert, review the previews and download a single image or all images as a ZIP.
Why and when to convert SVG to PNG
SVG is the ideal master format for logos, icons, charts and illustrations, but many places still need raster images. Social media profiles, marketplace listings, office documents, slide software, some email clients and older apps accept PNG or JPG but not SVG. App stores ask for icons at fixed pixel sizes, and print shops often request high-resolution PNGs. Converting from the SVG gives you a sharp image at exactly the resolution you need, instead of enlarging a small bitmap.
This converter handles one file or a batch of up to 50, which is useful for exporting a full icon set at 2× for a website or turning a folder of diagrams into PNGs for a report. Unlike the SVG Viewer & Optimizer, which displays and cleans SVG code, this tool produces downloadable raster files in PNG, JPG or WebP.
Worked example: an A4 drawing and an icon
Suppose an SVG declares width="210mm" height="297mm", the size of an A4 page. SVG uses CSS units, where one inch equals 96 pixels and 25.4 millimetres make an inch, so the intrinsic size is 793.7 × 1122.5 pixels. At a scale of 2× the PNG is 1587 × 2245 pixels. For print at 300 pixels per inch, choose Set width and enter 2480; keeping the proportions gives 2480 × 3507 pixels. Uncompressed in memory, the 2× image alone is 1587 × 2245 × 4 bytes, about 14.3 MB, which is why very large exports can fail on phones.
Icons often have only a viewBox, such as viewBox="0 0 24 24" with no width or height. The intrinsic size is then 24 × 24, and Set width 512 produces a 512 × 512 PNG. A wide logo with width="120" and viewBox="0 0 300 100" has an intrinsic size of 120 × 40. Exporting it at an exact 512 × 512 keeps the proportions by default: the drawing becomes 512 × 170.7 pixels, centred with an empty band of about 170.7 pixels above and below. Tick Stretch to fill only if you want it distorted to the full square.
How the conversion works
First the SVG is cleaned with DOMPurify. Scripts, event handler attributes, embedded web pages, links and references to external files are removed, while embedded data images and internal references such as gradients stay. The size is read from the width and height attributes, converted from units like mm, cm, in, pt and pc, or taken from the viewBox when the size is missing or given as a percentage. If neither exists, browsers use 300 × 150 pixels, and so does this tool.
The cleaned SVG is then given the exact output width and height, loaded into an image element and drawn on a canvas, with the background colour filled first if you chose one. The canvas is encoded as PNG, JPG or WebP by your browser. Exports are limited to 16,384 pixels per side and 64 megapixels in total. Several results are packed into one ZIP file, with duplicate names numbered automatically.
Common mistakes
Fonts are the classic surprise. An SVG that refers to a web font or a font installed on the designer's computer is drawn with a fallback font on yours, so the text may change shape or width. Convert text to outlines (paths) in your design app before exporting the SVG. Linked external images are also not loaded; embed them in the SVG instead.
Choosing JPG for artwork with transparency is another common slip: JPG cannot store transparency, so transparent areas are filled with the background colour you pick. Use PNG or WebP to keep transparent edges. Finally, exporting tiny SVGs at 1× often looks soft on high-density screens; export at the displayed size multiplied by 2 or 3.
Useful tips and limitations
- For crisp app icons and retina screens, export at 2× or 3× the size the image will be displayed at.
- If text looks different from your design app, convert the text to outlines before exporting the SVG, because web fonts referenced by the file are not loaded.
- Use WebP for web pages when you want transparency with smaller files than PNG.
- Check the intrinsic size line under each file; it explains when a percentage width was ignored or the 300 × 150 default was used.
Common questions
Does the SVG to PNG Converter keep transparency?
Yes, for PNG and WebP with Transparent selected. JPG has no transparency, so a background colour is always filled in.
How large can I export an SVG as PNG?
Up to 16,384 pixels on each side and 64 megapixels in total. Some phones and tablets have lower canvas limits, so choose a smaller size if an export fails.
Are scripts in an SVG file run during conversion?
No. Scripts, event handlers, embedded web pages and links to external files are stripped before the SVG is drawn as an image.
Why does my SVG convert at 300 × 150 pixels?
The file has no usable width, height or viewBox, so the browser default applies. Choose Exact width and height, or add a viewBox to the SVG.
Can I convert SVG to JPG with a white background?
Yes. Choose JPG; the background colour, white by default, fills transparent areas. You can pick any other colour.
Will animations in the SVG be kept?
No. The converter captures a single still frame of the SVG as it first appears. Animations and interactive features are not part of the PNG, JPG or WebP file.
SVG files and pasted code are converted in this browser and are not uploaded to ToolWorld Online. Save your downloads before closing the page.
