Best Image Format for QR Codes

SVG is the best format for QR codes because QR codes are geometric, vector-native graphics that need to scale from business card size to billboard size while remaining perfectly scannable. A QR code in SVG format renders with pixel-perfect precision at any resolution, ensuring reliable scanning regardless of the output size or medium.

PNG is the best raster alternative when SVG is not supported by your output context (social media uploads, certain print workflows, email). At sufficient resolution, PNG produces equally scannable results. JPG should never be used for QR codes because its lossy compression blurs the precise module boundaries that scanners depend on.

Here is how to generate, save, and use QR codes with maximum reliability.

Why SVG for QR Codes

QR codes are composed of discrete square modules arranged in a precise grid. This is inherently vector content: each module is a defined rectangle at a defined position. SVG represents these rectangles mathematically, meaning the code can scale from 1cm to 10 meters with zero quality loss.

For print materials, SVG is essential because the output size varies dramatically. The same QR code might appear on a business card (2cm), a product label (4cm), a poster (15cm), and a banner (50cm). A single SVG file works perfectly for all sizes. A raster PNG would need to be regenerated at the correct resolution for each size.

When to Use PNG

PNG is the correct choice when the output context does not support SVG, which includes most social media platforms, many email clients, and some printing workflows that require raster files.

Why JPG Fails for QR Codes

JPG is specifically designed to compress photographic content by discarding visual information that humans are unlikely to notice. QR code scanners are not human eyes. They rely on precise, high-contrast boundaries between black and white modules.

JPG compression creates a gradient transition at every module boundary instead of a crisp edge. At small sizes or when scanned at an angle, these blurred boundaries can cause scanner misreads or complete scan failures. Never save QR codes as JPG.

QR Code Sizing Guidelines

The minimum scannable size depends on the QR code's complexity (how much data it encodes) and the scanning distance.

Color and Contrast Rules

While QR codes are traditionally black on white, colored QR codes work if you maintain sufficient contrast.

Frequently Asked Questions

What format should QR codes be saved in?

SVG is the best format because QR codes are geometric graphics that scale perfectly as vectors. Use PNG when SVG is not supported by your output context. Never use JPG, as lossy compression blurs the precise module boundaries that scanners need.

What size should a QR code be for printing?

Minimum 2cm x 2cm (0.8 x 0.8 inches) for close-range scanning like business cards. For signage, the QR code side length should be at least one-tenth of the expected scanning distance. More data in the QR code requires a larger physical size.

Can I use a colored QR code?

Yes, but maintain at least a 4:1 contrast ratio between the dark modules and light background. Always keep dark modules on a light background, and test the colored code with multiple scanner apps before printing or publishing.

Why does my QR code not scan?

Common causes include insufficient contrast, too-small physical size, JPG compression blurring module boundaries, missing or too-narrow quiet zone (white border), or low error correction level combined with damage or obstruction. Regenerate as SVG or high-resolution PNG with adequate quiet zone.

Convert PNG to SVG concepts

Convert JPG to PNG for clean QR codes

Related Reading