QR codes have undergone a renaissance. From restaurant menus and event badges to product packaging and billboard advertising, quick-response codes are now the primary bridge between physical objects and digital experiences.
However, many marketing teams and developers still run into costly mistakes when creating QR codes: blurry raster exports that fail scanner cameras when printed large, broken codes when destination URLs change, and slow, bloated generation workflows.
Here is an architectural look at how modern programmable QR codes work, and how qr.href.nz elevates physical media integration.
1. Vector SVG vs. Raster PNG: why math matters in print
A QR code is fundamentally a 2D matrix of binary modules (black and white squares) arranged according to Reed-Solomon error correction algorithms.
When an online generator exports a low-resolution raster image (such as a 200x200 PNG):
- Scaling the bitmap up for a poster or packaging label causes pixel interpolation: the sharp edges of the modules blur into antialiased gray gradients.
- Mobile camera sensors rely on high-contrast edge detection to locate finder patterns (the three large squares in the corners). Blurred edges increase scan latency and cause scan failures in low-light environments.
By exporting native Vector SVG (<svg> elements rendered mathematically with <rect> or <path> elements):
- The file can be scaled infinitely from a 1-inch business card to a 20-foot highway billboard without losing a micron of sharpness.
- SVG assets can be embedded directly into automated print layout pipelines (InDesign, Figma, Illustrator, or PrinceXML automated PDF engines).
2. Static payloads vs. Dynamic short-link redirects
When designing a QR code, you must decide what data to encode in the modules:
Direct Payloads (No Server Roundtrip)
For offline-capable or self-contained interactions, the payload is encoded directly into the code itself:
- Wi-Fi Config:
WIFI:T:WPA;S:MyNetwork;P:MySecretPass;;allows smartphones to join guest networks instantly without typing passwords. - vCard 4.0: Contact cards encoded with name, phone, email, and social profiles import directly into the user's native Contacts app with zero network calls.
- Cryptocurrency & Geo Coordinates: Fast, verifiable wallet transfers and location coordinates.
Dynamic Redirects (Changeable Targets)
Once ink meets paper, you cannot edit physical print. If your marketing campaign changes, or if an old URL 404s, a static QR code is permanently ruined.
By pointing the QR code to an immutable short link (such as href.nz/spring-promo), you decouple physical print from digital logic:
- You can redirect traffic to a new landing page six months after the brochure was printed.
- You can activate password protection or schedule link expiration after an event concludes.
- You collect real-time scan volume and geographic telemetry without compromising user privacy.
3. Automating QR generation with the REST API
High-volume transactional workflows (e.g. event ticketing, shipping invoices, and dynamic badge printing) cannot rely on manual web exports.
Using the qr.href.nz API, generating a dynamic QR code requires only a single HTTP request:
curl -X GET "https://qr.href.nz/api/v1/qr?url=https://href.nz/summer-fest&format=svg&size=512&margin=2" \
-o ticket-badge.svg
Developers can configure:
format:svgfor vector print pipelines, orpngfor direct web rendering.size: Output dimensions in pixels (for PNG) or viewBox units (for SVG).error_correction: LevelL(7%),M(15%),Q(25%), orH(30% redundancy, allowing embedded logos without compromising decodability).
Whether you're printing 50 business cards or automating 50,000 packing slips, vector precision and programmable endpoints ensure your physical media stays sharp and functional. Try it live at qr.href.nz.