SVG: a drawing written as code
An SVG describes shapes, like “a circle 40 px wide, filled orange”. Because it’s instructions and not pixels, it stays sharp at any size.
Paste SVG code on the left
Or drop one or more .svg files here. You’ll see the PNG at the size it will be saved.Making your picture…
It turns an SVG drawing into a PNG picture. You paste the SVG code or open the file, pick a size, and download a PNG that looks exactly like the preview. You need this more often than you’d think: app stores, social sites, email, slides and plenty of upload forms take PNG but not SVG.
The conversion runs in your browser. Your files aren’t uploaded anywhere, and the picture is saved straight from this page.
An SVG describes shapes, like “a circle 40 px wide, filled orange”. Because it’s instructions and not pixels, it stays sharp at any size.
A PNG stores the color of every pixel, so it opens everywhere and can have a see-through background. Make it bigger than it was saved, though, and it gets blurry.
<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100">
<circle cx="50" cy="50" r="40" fill="#f97316"/>
</svg> That’s an orange circle on a 100 × 100 px canvas. Load it, type 512 in the W box, and you get a 512 × 512 px PNG with perfectly smooth edges.
| SVG | PNG | |
|---|---|---|
| Best for | Logos and icons on your own website | Anywhere that only takes pictures |
| Sharp at any size | Yes | Only up to the size it was saved at |
| Transparent background | Yes | Yes |
| Accepted by | Browsers, design apps | Almost everything: app stores, social sites, email, Word, slides |
| Can be edited as text | Yes | No |
A good habit: keep the SVG as your original, and make PNGs from it whenever something asks for one. On your own pages, the SVG usually works best, since one small file looks sharp on every screen. The HTML images tutorial shows how to put either one on a page.
Click Sample in the tool above to follow along with a coffee cup.
<svg> in it and the tool uses that part.The preview on the right is the real PNG, drawn again each time you change something.
W and H start at the SVG’s own size. Type a new width and the height follows,
so a 24 × 24 icon at W 512 becomes 512 × 512. Click the padlock to set both sides yourself; the drawing is then
fitted inside that box and centered, so it keeps its shape. (One exception: an SVG with
preserveAspectRatio="none" on its <svg> tag asks to be stretched, so it fills the box.)
Original takes you back to the SVG’s own size.
Scale multiplies everything. 2x turns a 256 px drawing into a 512 px PNG, which looks crisp on phones and high-resolution laptops. Custom takes any number from 0.1 to 20, like 1.5. The status line under the preview always shows the final size in pixels and, once it’s made, the file size.
These are the sizes people ask for most. Type the width in the W box (or the height in H).
| Use | Size | Notes |
|---|---|---|
| App icon (Google Play) | 512 × 512 px | Square SVG, PNG format. |
| Social share image | 1200 × 630 px | What most sites show in link previews. Turn the padlock off and type both sides. |
| Favicon | 16, 32, 48 px and more | The Favicon Generator makes every size plus the .ico file in one go. |
| Logo on a website | 2x the size it’s shown | A logo shown 200 px wide looks sharpest as a 400 px PNG. |
| 300 px per inch | A logo printed 4 inches wide needs 1200 px. |
<!-- 24 × 24 px, and it scales cleanly -->
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
<!-- 48 × 48 px: the drawing is scaled up 2x -->
<svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 24 24"> The viewBox is the SVG’s own coordinate system. With no width and height, the tool uses the viewBox numbers as pixels. When you type a bigger width, the shapes are drawn again at that size, so you never get the blurry look of a stretched picture.
When an SVG is turned into a picture, browsers treat it like an image on a web page: nothing outside the file is loaded. That’s the rule that keeps it safe, and it’s the reason for most “why is it blank?” moments. The tool checks your SVG and tells you above the preview when it spots one of these.
An <image href="photo.jpg"> points at another file, so it can’t load, and the tool leaves it
out of the picture. Its spot stays empty. Put the image inside the SVG as a data: URI. In Inkscape, choose Embed when you import the image.
Fonts from @import or @font-face links don’t load either, so text uses a font from your
device. Turn the text into paths before you export: Inkscape Path > Object to Path,
Illustrator Type > Create Outlines.
Text in Arial, Georgia or any font on your device draws fine. Someone else converting the same SVG on a computer without that font gets a different look, though, which is why paths are the safe choice.
Icon sets often use currentColor, which borrows the text color of the page. On its own there’s no
page, so it’s black. Swap it for a real color code before converting.
<svg xmlns="http://www.w3.org/2000/svg" width="320" height="140" viewBox="0 0 320 140">
<rect width="320" height="140" rx="14" fill="#1e293b"/>
<image href="https://example.com/team.jpg" x="20" y="20" width="100" height="100"/>
<text x="140" y="80" fill="#f8fafc" font-family="Georgia, serif" font-size="24">Our team</text>
</svg> Load it and the tool warns you that the photo is an outside file. The dark card and the “Our team” text still come through; the photo is left out, so its spot stays empty.
Put the image inside the SVG:
<!-- Left out: the photo is a separate file -->
<image href="https://example.com/team.jpg" width="100" height="100"/>
<!-- Works: the photo is inside the SVG -->
<image href="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQ…" width="100" height="100"/> Give currentColor a real color:
<!-- Before: black on its own -->
<svg … stroke="currentColor">
<!-- After: always rose red -->
<svg … stroke="#e11d48"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linejoin="round">
<path d="M12 20s-7-4.4-9.2-8.6A5 5 0 0 1 12 6.5a5 5 0 0 1 9.2 4.9C19 15.6 12 20 12 20z"/>
</svg>
This heart has only a viewBox, so it starts at 24 × 24 px, and it uses currentColor, so it’s black. Load it, type
512 in W, then change currentColor to #e11d48 in the code. You’ll get a big rose-red heart.
SVGs are see-through wherever nothing is drawn, and a PNG keeps that by default. The checkerboard behind the preview marks the see-through parts. If you’d rather have a solid background, pick White or Color; with some Padding that’s an easy way to make a square app icon from a logo that isn’t square.
JPG has no transparency at all, so when you pick JPG the background turns white (or your color). WebP can be transparent, just like PNG.
<img> tag on a site.<foreignObject>) draws in Chrome, but other browsers, Safari
most of all, can leave it blank or refuse to save it.
Paste your SVG code into the box on the left, or open or drop an .svg file. The preview on the right is the real PNG. Type a width if you want it bigger or smaller, pick a background, then click Download PNG. It all happens in your browser, so nothing is uploaded.
Leave Background on Transparent (it’s the default) and keep the format on PNG or WebP. The checkerboard in the preview shows which parts will be see-through. JPG can’t store transparency, so a JPG always gets a white background, or the color you pick.
Type the width you need, like 1024, or pick 2x, 3x or 4x. An SVG is made of shapes, not pixels, so the shapes are drawn again at the new size and the edges stay sharp. That’s different from stretching a small PNG, which always gets fuzzy. The status line under the preview shows the final size in pixels.
If it has a viewBox, like viewBox="0 0 24 24", that’s used as the size, so an icon comes out 24 × 24 px. Type a width such as 512 to make it bigger, and the height follows the viewBox shape. With no width, height or viewBox at all, browsers draw an SVG at 300 × 150 px, so that’s what you get, and the tool tells you.
When an SVG is drawn as a picture, browsers don’t load anything from outside the file: no linked images, no web fonts, no outside stylesheets. The tool lists what it found. To fix it, put the image inside the SVG as a data: URI, and turn text into paths in your design app (Inkscape: Path > Object to Path, Illustrator: Type > Create Outlines). Text in a font that’s installed on your device still works.
Yes. Pick several files in the Open dialog, or drop them all on the tool. They show up as tabs above the editor, so you can check each one. Download all (.zip) converts every file with the same settings and gives you one zip. A file with a mistake in it is left out, and the tool says which one and why.
Yes. The SVG is only ever drawn as an image, the same way an <img> tag on a website shows it. In that mode browsers never run the scripts inside an SVG and never load outside files, so nothing in it can reach this page or the internet. Your files stay on your device; only your settings, like the size and background, are remembered in this browser.
PNG keeps the sharp edges of logos and icons and can be transparent, so it’s the usual pick for an SVG. JPG makes smaller files but softens edges and can’t be transparent. WebP is small like JPG and can be transparent like PNG, and every modern browser opens it. JPG and WebP get a Quality slider.