REST API · PNG & SVG

Generate QR codes
with one API call

Customizable QR codes with colors, sizes, error correction, and multiple output formats. Lightning fast, no browser needed.

bash
curl "https://snapapis.com/api/v1/qr/generate?api_key=YOUR_KEY&data=https://example.com&size=400" \
  --output qrcode.png

Full customization

Every QR code tailored to your brand

Custom Colors

Set foreground and background colors to match your brand identity.

Multiple Formats

Output as PNG for pixel-perfect images or SVG for infinite scalability.

Error Correction

Choose L/M/Q/H correction levels. Higher levels allow the code to stay readable even when partially damaged.

Custom Sizes

Generate from 50px to 2000px. Perfect for everything from tiny icons to large print materials.

URLs & Text

Encode any data — URLs, text, WiFi credentials, vCards, email addresses, and more.

Blazing Fast

QR codes generated in under 50ms. No browser, no Puppeteer — pure server-side rendering.

API Parameters

Full control over every QR code

Parameter Type Default Description
data string required Content to encode (URL, text, etc.)
size int 300 Image size in pixels (50-2000)
format string png Output format: png, svg
error_correction string M Error correction: L, M, Q, H
margin int 2 Quiet zone margin (0-10)
foreground_color string #000000 Foreground hex color
background_color string #FFFFFF Background hex color
response_type string image image (binary) or json (base64)

Ready to generate?

Get your API key in seconds and start generating QR codes.