Skip to content

SVG or PNG for a QR Code: Which File to Download and Where Each Works

What separates an SVG QR code from a PNG one, which file suits print, screens and design software, and how to keep the code scannable.

Get Stash

Quick answer

Download SVG for anything printed or scaled up, because it is drawn from shapes and stays sharp at any size. Download PNG at 1,024 pixels or more for email, slides, documents and upload forms that only take images.

For print
SVG. Posters, signs, packaging and business cards can be any size without soft edges, and print shops and design apps open it.
For screens
PNG. Email signatures, slides, chat messages and website uploads accept PNG almost everywhere. Use 1,024 or 2,048 pixels.
Never skip
The blank margin. QR codes need a quiet zone four modules wide on every side, in both formats.
When to use a vault
When the code holds a Wi-Fi password, a private link or contact details, and its image should not sit in the camera roll or iCloud Photos.

Best overall: Stash

A QR code image saved to the iPhone lands in the Photos library, where it syncs with iCloud Photos and opens with the phone's passcode, even when the code holds a Wi-Fi password or a private link. Stash keeps chosen photos and files behind a PIN of its own, inside a working calculator. Imported items are encrypted on the iPhone with AES-256, stay outside the Photos library and are not uploaded by iCloud Photos. Stash is free to download with no ads, so the calculator, the PIN and the encrypted vault are ready from the first launch.

What separates an SVG QR code from a PNG

Both files show the same pattern of black and white squares. The difference is how that pattern is stored.

A PNG is a raster image: a fixed grid of pixels, each with a colour. The W3C's PNG specification, now in its third edition (W3C Recommendation of 24 June 2025), describes it as a format "for the lossless, portable, well-compressed storage" of raster images (PNG Specification, Third Edition). Lossless means every pixel comes back exactly as it was saved, which is good for a QR code. But the number of pixels is set when the file is made. Stretch a 512-pixel PNG across a poster and each pixel becomes a large block, and the edges between them get smoothed into grey.

An SVG is a set of drawing instructions. The W3C describes SVG as "a language based on XML for describing two-dimensional vector and mixed vector/raster graphics" and says SVG content is "scalable to different display resolutions" (Scalable Vector Graphics (SVG) 2, Candidate Recommendation snapshot of 6 October 2026). A QR code in SVG is a list of squares with exact positions. A printer or a screen draws them fresh at whatever size is needed, so the edges stay crisp at 2 centimetres or 2 metres.

Mozilla's developer reference gives the same split: SVG is "ideal for user interface elements, icons, diagrams, etc., that must be drawn accurately at different sizes", while PNG is preferred "for more precise reproduction of source images" (MDN image file type guide, as of 2 December 2026). All major browsers display both.

Why a QR code cares more about sharp edges than a photo

A photo can lose a little sharpness and still look fine. A QR code is read by software that has to decide, square by square, whether each module is dark or light. Soft, grey edges make that decision harder, and so do small modules.

Three things decide whether a printed or displayed code scans well:

  • Module size. Each small square is a module. Denso Wave, the company that invented the QR code, gives a worked example: a 400 dpi printer using 4 dots per module prints modules of 0.254 mm (qrcode.com, Module size, as of 2 December 2026). More data in the code means more modules in the same space, and so smaller ones.
  • The quiet zone. Denso Wave states that a QR code "requires a four-module wide margin at all sides of a symbol." Cropping that blank border off to save space is a common reason a code fails.
  • Contrast. A dark code on a light background reads best. Many scanners do not read light-on-dark codes.

The format matters because of the first point. An SVG keeps module edges exact at any size. A PNG keeps them exact only at its own size or at a clean whole-number multiple of it.

Which format to pick, by where the code goes

Where the code goes Best file Why
Poster, sign, banner, window sticker SVG Scales to any size with sharp edges
Business card, flyer, menu sent to a print shop SVG (or PNG at 2,048 px) Vector artwork prints cleanly; a large PNG works if the shop asks for an image
Packaging and product labels SVG Designers place it as a vector in the artwork
Email signature PNG PNG is the safe choice for an image inside an email signature
Slides (Keynote, PowerPoint, Google Slides) PNG at 1,024 px Opens everywhere; large enough for a projector
Website or blog post SVG or PNG Browsers show both; SVG stays crisp on high-resolution screens
Chat message or social post PNG Messaging apps and social sites expect a photo-type image
Online form that asks for "an image" PNG Many upload forms list only JPEG and PNG

Avoid JPEG for QR codes. JPEG is lossy, so it adds faint blotches around sharp edges, exactly where the scanner looks.

How to make and download a QR code in SVG and PNG

The QR code generator on this site makes both files from the same code. It works in the open browser tab: what you type, including a Wi-Fi password, is not sent to a server.

  1. Open the generator and pick the type: Link, Text, Wi-Fi, Contact, Email or SMS.
  2. Fill in the fields. The code updates as you type.
  3. Choose the error correction. Denso Wave notes that "Level M (15%) is most frequently selected", and suggests Q or H where codes may get dirty and L for clean settings with a lot of data (qrcode.com, Error correction).
  4. Choose the PNG size: 256, 512, 1,024 or 2,048 pixels. The SVG scales freely and ignores this setting.
  5. Keep dark-on-light colours. The tool warns when contrast is low or the code is lighter than its background.
  6. Scan the code on screen with your phone before you save it.
  7. Press Download SVG, Download PNG, or both. Both files include the four-module quiet zone.

The codes are static: the content sits in the pattern itself, so neither file depends on a server or expires. The guide to a free business card QR code covers what to put on a contact code.

Working with the SVG file

  • Place it, do not trace it. Drag the SVG into Illustrator, Affinity, Figma, Inkscape or a print shop's upload page as it is.
  • Resize with the lock on. Keep the width and height equal. A stretched code has rectangular modules and may not scan.
  • Recolour with care. You can change the fill in a design app, but keep the code darker than the background and the contrast strong.
  • Leave the margin. Do not set the artwork's edge tight against the code; the quiet zone is part of the symbol.

If you have to use the PNG

  • Export big, then shrink. A 2,048-pixel PNG scaled down in a document stays sharp; a 256-pixel PNG scaled up does not.
  • Scale by whole numbers where you can. 200% or 400% keeps each module a clean block; 137% blurs the edges.
  • Do not compress it as a JPEG. If a site converts uploads to JPEG, upload the largest PNG you have so the damage stays small.

Is the PNG or the SVG better for privacy?

Neither file carries the date, device or location the way a camera photo does. The images this generator makes are drawn fresh, so there is nothing to strip. What a QR code does carry is its content, in plain sight to anyone with a camera: a Wi-Fi code holds the network password, a contact code holds your phone number, a link code holds the address. The photo metadata viewer on this site shows what a photo file holds, if you want to check a picture of a code you received.

The bigger question is where the image ends up. Saving a code to Photos on an iPhone puts it next to every other photo, and with iCloud Photos on it syncs to every device on the Apple Account.

When a downloaded QR code is enough

For most codes, a file on your computer or in Photos is fine:

  • The code points to a public website, a menu or a business card.
  • The Wi-Fi code is for a guest network you are happy to share.
  • Nobody else uses or knows the passcode of the device where the file is saved.

When you need more than a downloaded file

Some codes are keys, not signs:

  • A Wi-Fi code for your home network. Anyone who scans the image joins your network.
  • A code with a private link, such as a shared folder, a document or a meeting room.
  • Codes and photos of codes you received, such as event tickets, boarding passes, membership cards or a colleague's contact code.
  • A phone that other people pick up. Everything in the Photos library opens with the phone's passcode.

How to keep private QR codes with Stash

Stash looks and works like a calculator. Your PIN opens the vault, and photos and files you import are encrypted on your device with AES-256, with the key kept in the iOS Keychain. They are stored inside the app, not in your Photos library.

  1. Make the code and save the PNG to Photos (on iPhone, Save or share PNG, then Save Image).
  2. Install Stash from the App Store. It runs on iPhone and iPad with iOS 15 or later.
  3. Open it, choose your PIN and write down the recovery key that Stash shows once during setup.
  4. In the vault, tap + and import the QR code image. Sort codes into an album such as "Wi-Fi" or "Tickets" if you like.
  5. Back in Photos, delete the original, then delete it again in Recently Deleted.
  6. Optional: turn on Face ID or Touch ID and auto-lock in Stash. Premium adds a guest PIN that opens a separate vault.

When you need the code, open the vault and show it on screen; a scanner reads it from the display.

FAQ

Is an SVG QR code higher quality than a PNG?

At its own size, a PNG is just as sharp, because PNG is lossless. The SVG wins as soon as the code is printed or shown larger than the PNG's pixel size, because it is redrawn at every size.

Can I change the colour of an SVG QR code?

Yes, in any vector design app. Keep the code dark on a light background with strong contrast, or some scanners will fail.

Why does my printed QR code look blurry?

Most often a small PNG was enlarged. Download the SVG, or a PNG at 2,048 pixels, and print again.

Do print shops accept SVG files?

Ask the shop which files it takes. Many want vector artwork as SVG or PDF, and a design app can export a PDF from the SVG; if the shop only takes images, send the largest PNG.

Can I turn a PNG QR code into an SVG later?

Tracing a PNG into an SVG can distort the modules. It is safer to make a new code from the same content and download the SVG; the generator's Text inside the code panel shows what went in.

Which PNG size should I download?

1,024 pixels for screens, slides and email; 2,048 pixels for print if you cannot use SVG.

Does the quiet zone matter if the background is white anyway?

Yes. The white border must be clear of text, lines and other artwork for four modules on every side. A white page counts, as long as nothing is printed in that margin.

The Bottom Line

An SVG QR code is made of shapes, so it stays sharp at any print size; a PNG is a fixed grid of pixels that is sharp at its own size and soft when stretched. That is the whole choice, and the table above sorts it by destination: SVG for posters, signs, packaging and print shops, PNG at 1,024 or 2,048 pixels for email, slides, chat and upload forms. In both formats, keep the four-module quiet zone, keep the code dark on light, and test it with a phone before it goes out.

The file format does not change what the code reveals. A Wi-Fi code or a private link works for anyone who points a camera at it, so codes like that belong in a place with its own lock rather than in the camera roll.

·Written by the developer of Stash

Save this guide

Summary of this guide as an image: SVG or PNG for a QR Code: Which File to Download and Where Each WorksDownload this guide as an image