How to Create Dynamic QR Codes

Learn how to create QR codes with editable destinations. Update where your QR codes point without reprinting them.

📅 Updated December 2025 ⏱️ 6 min read

Static vs Dynamic QR Codes

Before diving in, let's understand the difference:

How Dynamic QR Codes Work

📱 User Scans
qrcodeapi.io/r/abc123
Your Destination

The redirect URL stays the same, but you can change where it points.

Creating a Dynamic QR Code

Use the Links API to create a dynamic link, then generate a QR code for it:

Step 1: Create a Dynamic Link
const response = await fetch('https://www.qrcodeapi.io/api/links', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    name: 'Summer Menu 2024',
    destinationUrl: 'https://yoursite.com/menu/summer'
  })
});

const link = await response.json();
// link.shortCode = 'abc123'
// link.qrUrl = 'https://www.qrcodeapi.io/r/abc123'
Step 2: Generate QR Code for the Link
const qrResponse = await fetch('https://www.qrcodeapi.io/api/generate', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    data: link.qrUrl,  // Use the redirect URL
    size: 400,
    format: 'png'
  })
});

// Print this QR code - it will always redirect through your dynamic link

Updating the Destination

When you need to change where the QR code points, simply update the link:

Update Destination URL
await fetch(`https://www.qrcodeapi.io/api/links?id=${link.id}`, {
  method: 'PUT',
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    destinationUrl: 'https://yoursite.com/menu/fall'  // New destination
  })
});

// All existing QR codes now redirect to the new URL!

Use Cases for Dynamic QR Codes

Restaurant Menus

Print QR codes on table tents once. Update menus daily for specials, seasonal items, or price changes without reprinting.

Marketing Campaigns

Print QR codes on flyers or billboards. Redirect to different landing pages based on campaign phase or A/B tests.

Product Packaging

Include QR codes on packaging that link to user guides, warranty registration, or promotional offers that change over time.

Real Estate

Same yard sign QR code can redirect to different property listings as homes sell and new ones come on market.

Benefits of Dynamic QR Codes

Ready to Create Dynamic QR Codes?

Get started with dynamic links and never reprint a QR code again.

Get Your Free API Key