# DPI (dots per inch)

> DPI is printing resolution. For QR codes it matters because each module must be rendered from a whole number of printer dots — 300 dpi is the practical minimum, and generating from vector rather than raster avoids the problem entirely.

Source: https://useqr.app/glossary/dpi · Last reviewed 2026-08-21 · UseQR is free forever, MIT licensed, no signup.

---

## The arithmetic

At 300 dpi, one dot is 0.085 mm. A 0.5 mm module is about 6 dots — comfortably resolvable.
At 150 dpi it is 3 dots, and rounding errors start shifting module boundaries.

## Why vector is better

An SVG has no resolution: the RIP renders each module at the output device's native
resolution with exact edges. A raster PNG scaled up to fit a poster interpolates, softening
every boundary — and soft boundaries are precisely what a decoder's thresholding step
struggles with.

Always send SVG or PDF to a printer. Use PNG only when the destination cannot take vector.

## If you must use raster

Generate at final size × target dpi, and never scale up. For a 5 cm code at 300 dpi that is
591 px. Turn off any smoothing or resampling in the layout tool.
