QR Code Generator

Make a QR code for a link, Wi-Fi, an email or a phone number, and download it as SVG or PNG.

Error correction

Medium: about 15% recoverable, and the level most codes use.

The code
The QR code

The code says
Quackyard 🦆

Version 1: 21 × 21 modules for 14 bytes of UTF-8, at level M.

Runs in your browser. Nothing you enter is sent anywhere.

How to use it

  1. Pick what the code is for: Text, Link, Wi-Fi, Email or Phone, then fill in its fields.
  2. Choose an Error correction level: L, M, Q or H. The page starts on M.
  3. Press Download SVG or Download PNG.

The code redraws as you type, in your browser. The code says shows the exact text a scanner will read, and the line under it gives the version, the size in modules and the bytes used. Both files keep the four-module white border a scanner needs. The PNG is at least 1,024 pixels wide.

Examples

The link https://quackyard.com at level M makes a version 2 code, 25 × 25 modules for 21 bytes. At H the same link needs version 3, 29 × 29.

A Wi-Fi network named Duck;Pond, with WPA/WPA2 and the password a"b\c:

WIFI:T:WPA;S:Duck\;Pond;P:a\"b\\c;H:false;;

The semicolon, quote and backslash are escaped, so a phone doesn’t read them as part of the format.

An email to [email protected] with the subject Quack and a short message:

mailto:[email protected]?subject=Quack&body=Hello%20from%20the%20pond.

The phone number +1 555 0100 becomes tel:+15550100. RFC 3966 doesn’t allow spaces in a tel: URI, so they’re dropped; hyphens, dots and brackets stay.

Too much text is refused: 2954 bytes of UTF-8 is more than a QR code can hold: at level L the limit is 2953. Shorten it, or ask for less error correction.

Good to know

  • Error correction trades size for toughness. ISO/IEC 18004 puts the share of a damaged code that can still be read at about 7% for L, 15% for M, 25% for Q and 30% for H, and the higher the level, the bigger the code.
  • Capacity is counted in UTF-8 bytes. The most a code holds is 2,953 bytes at L, 2,331 at M, 1,663 at Q and 1,273 at H, in version 40, which is 177 × 177 modules. é takes 2 bytes and 🦆 takes 4. Every code here uses byte mode, so a string of digits takes as much room as letters.
  • The email address is percent-encoded as well as the message. RFC 6068 has %, ?, #, &, = and the other characters that mean something in a mailto: URI escaped in the address, and anything outside ASCII sent as its UTF-8 bytes, so [email protected] becomes mailto:unlikely%[email protected]. A line break in the message goes out as %0D%0A.
  • The Wi-Fi line is the format phone cameras read. It comes from the ZXing project and is understood by the iPhone and Android cameras. No password writes T:nopass and leaves the password out; Hidden network writes H:true.
  • Keep the border and the contrast. Print dark modules on a light background; not every scanner reads a code with the colors inverted.

Questions

How do I make a QR code for Wi-Fi?

Choose Wi-Fi, type the Network name (SSID) exactly, capitals included, pick the security and enter the Password. A phone camera pointed at the code offers to join the network.

Do these QR codes expire?

No. The code holds the data itself, with no redirect service in between, so it works as long as what it points to does. Changing it means making a new code.

Which error correction level should I use?

M suits most codes. Use L to keep a long payload small, and Q or H for print that may get scuffed or folded.

Should I download the SVG or the PNG?

The SVG for print and design tools, because it stays sharp at any size; the PNG where SVG isn’t accepted, as in many documents and chat apps.