CompoundPage

vCard QR Code Generator

A vCard QR code generator puts a contact in a phone's address book in one scan, if the record is short enough to read. A vCard 3.0 record, newline-separated, between BEGIN:VCARD and END:VCARD. The working example below is 87 bytes, which fits a version 5 code at level L.

A URL, some text, or a structured payload like WIFI: or mailto:.

Higher levels survive more damage and need a bigger code.

QR codeVersion 5, level L

BEGIN:VCARD VERSION:3.0 N:Khan;Aisha TEL:+15551234567 EMAIL:aisha@example.com END:VCARD
Version
5 (37 x 37 modules)
Error correction
L - Low, recovers about 7%
Payload
87 of about 106 bytes used
Mask The lowest penalty of the eight mask patterns, which scored 941, 949, 927, 944, 821, 1013, 922, 950.
4 of 0-7, penalty 821

How the QR Code Generator works

This generator encodes a contact details payload. The grammar is: A vCard 3.0 record, newline-separated, between BEGIN:VCARD and END:VCARD.

The example above, BEGIN:VCARD / VERSION:3.0 / N:Khan;Aisha / TEL:+15551234567 / EMAIL:aisha@example.com / END:VCARD, is 87 bytes, which at error correction level L fits a version 5 symbol, 37 modules square. The encoder scored all eight mask patterns and chose 4, which is not a preference: the specification requires the lowest-penalty mask, so any correct encoder given this text produces this identical image.

The biggest payload anyone routinely puts in a QR code, and size is the whole problem: a full vCard with a job title, a company and an address runs past 200 bytes and forces a dense symbol that a phone camera struggles with at business-card scale. Three ways out, in order of preference: drop to error correction L, cut the record to name, phone and email, or encode a link to a contact page instead. The grammar itself is strict: VERSION:3.0 is required, the N: field is surname-first and semicolon-separated, and lines end with a plain newline. MECARD is a terser alternative that Android handles well and iOS handles inconsistently, which is why vCard remains the safer choice.

On the error correction level: L recovers about 7% of the symbol. That is the single most useful dial on a QR code and the one most often left alone. Raising it costs capacity, which pushes the version up, which makes each module smaller at the same printed size. So the right level is the lowest one that survives where the code will live. A code on a screen needs almost none; a code on a sticker on a machine needs a lot.

Nothing about this is sent anywhere. The code is built from the text in the field, in your browser, and the site has no server that could receive it. It also does not expire, because there is no redirect in it: what the camera reads is your payload, not a reference to a row in somebody's database. A QR code that goes through a shortener stops working the day the shortener does.

QR Code Generator FAQ

What is the exact format for a contact details QR code?

A vCard 3.0 record, newline-separated, between BEGIN:VCARD and END:VCARD. The working example above is BEGIN:VCARD / VERSION:3.0 / N:Khan;Aisha / TEL:+15551234567 / EMAIL:aisha@example.com / END:VCARD.

What goes wrong with this format?

The biggest payload anyone routinely puts in a QR code, and size is the whole problem: a full vCard with a job title, a company and an address runs past 200 bytes and forces a dense symbol that a phone camera struggles with at business-card scale. Three ways out, in order of preference: drop to error correction L, cut the record to name, phone and email, or encode a link to a contact page instead. The grammar itself is strict: VERSION:3.0 is required, the N: field is surname-first and semicolon-separated, and lines end with a plain newline. MECARD is a terser alternative that Android handles well and iOS handles inconsistently, which is why vCard remains the safer choice.

How big does this code come out?

87 bytes at level L gives a version 5 symbol, 37 by 37 modules. Each version is four modules wider than the last (21, 25, 29 and so on), so adding a few characters can jump the whole symbol up a size. Print it at least 2 cm across, and keep the four-module quiet zone around it.

Does it expire, or track anyone?

Neither. The payload is encoded directly into the image, so there is no redirect to switch off and nothing to log. The encoding happens in your browser, on your own device.

More from the QR Code Generator

Related calculators

Embed this calculator
<div id="compoundpage-qr-code-generator"></div>
<script src="https://compoundpage.com/embed/qr-code-generator.js" async></script>

The same calculation as JSON