2D Free plan

QR Code Generator API

The most popular 2D barcode for mobile scanning

Sample QR Code barcode

Generated live by the BarGen API from https://bargen.pro

QR Code is the two-dimensional matrix barcode standardized in ISO/IEC 18004, originally developed by Denso Wave for automotive parts tracking and now the most widely deployed 2D symbology in the world. It arranges data into a square grid of black and white modules and stores URLs, plain text, contact cards, or binary payloads, with built-in Reed-Solomon error correction that keeps the code scannable even after partial damage.

BarGen generates a QR Code from a single REST call: send the data string and desired size, and the API returns an SVG or PNG image ready to embed in a web page, print job, or PDF. Error correction level, module color, and quiet zone are all configurable parameters.

QR Code (Quick Response Code) is a two-dimensional matrix barcode invented in 1994 by Denso Wave, a Japanese automotive company. Originally designed for tracking parts in vehicle manufacturing, it has become the most widely used 2D barcode format worldwide.

QR codes can store various types of data including URLs, text, contact information, WiFi credentials, and more. They can hold up to 7,089 numeric characters or 4,296 alphanumeric characters, making them incredibly versatile for many applications.

One of the key features of QR codes is their error correction capability. Even if part of the code is damaged or obscured, it can still be read. This makes them ideal for printed materials that may get worn or partially covered.

Common use cases include mobile payments, product packaging, event tickets, restaurant menus, marketing campaigns, and authentication systems.

Common use cases

Marketing and URL redirects

Print media and packaging use QR Codes to route customers to landing pages, app stores, or promotional content without typing a URL.

Two-factor authentication

Authenticator apps and login flows encode TOTP secrets or session tokens in a QR Code for a single-scan pairing step.

Menus and check-in systems

Hospitality venues and event organizers use QR Codes for contactless menus, table ordering, and ticket check-in.

Generate QR Code via the REST API

curl "https://api.bargen.pro/v1/barcode/qrcode?data=https%3A%2F%2Fbargen.pro&format=svg" \
  -H "X-API-Key: YOUR_API_KEY"

Returns the barcode as SVG. See the API documentation for all options.

Frequently asked questions

How much data can a QR Code hold?

A full-size QR Code can encode up to 7,089 numeric digits or 4,296 alphanumeric characters, depending on the version and error correction level chosen.

What do the QR Code error correction levels mean?

ISO/IEC 18004 defines four levels, L, M, Q, and H, recovering roughly 7%, 15%, 25%, and 30% of the symbol respectively. Higher levels add resilience to smudges or partial occlusion at the cost of a denser code.

What is the difference between QR Code and Micro QR?

Micro QR is a smaller, single-alignment-pattern variant of the same standard aimed at low-capacity, space-constrained labels, while standard QR Code scales up to much larger payloads.

Specifications

Capacity
Up to 7,089 numeric or 4,296 alphanumeric characters
Error Correction
L (7%), M (15%), Q (25%), H (30%)
Module Size
21×21 to 177×177

Availability

Available from the Free plan.

See pricing

Start generating QR Code barcodes

Free tier with 1,000 API calls per month. No credit card required.