WiFi QR Code Generator
A WiFi QR code generator lets guests join by scanning, as long as every separator is right. WIFI:T:TYPE;S:SSID;P:PASSWORD;H:HIDDEN;;, where TYPE is WPA, WEP or nopass and HIDDEN is true for a network that does not broadcast its name. The working example below is 34 bytes, which fits a version 4 code at level Q.
QR code
- Version
- 4 (33 x 33 modules)
- Error correction
- Q - Quartile, recovers about 25%
- Payload
- 34 of about 46 bytes used
- Mask The lowest penalty of the eight mask patterns, which scored 887, 893, 769, 951, 847, 949, 1086, 723.
- 7 of 0-7, penalty 723
How the QR Code Generator works
This generator encodes a Wi-Fi payload. The grammar is: WIFI:T:TYPE;S:SSID;P:PASSWORD;H:HIDDEN;;, where TYPE is WPA, WEP or nopass and HIDDEN is true for a network that does not broadcast its name.
The example above, WIFI:T:WPA;S:MyNetwork;P:hunter2;;, is 34 bytes, which at error correction level Q fits a version 4 symbol, 33 modules square. The encoder scored all eight mask patterns and chose 7, which is not a preference: the specification requires the lowest-penalty mask, so any correct encoder given this text produces this identical image.
The format that costs people the most time, because every one of its quirks fails silently. The double semicolon at the end is mandatory and a single one does nothing. The fields are order-insensitive but the labels are case-sensitive: S: not s:. If the network name or password contains a semicolon, comma, colon, backslash or double quote, each must be escaped with a backslash. An unescaped semicolon in a password truncates it, and the phone will try to join with the wrong credentials and report a bad password. For an open network use T:nopass and omit P: entirely rather than giving an empty password. Use error correction Q or H: this code usually ends up printed small and taped to a wall, which is the worst case for a scanner.
On the error correction level: Q recovers about 25% 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 Wi-Fi QR code?
WIFI:T:TYPE;S:SSID;P:PASSWORD;H:HIDDEN;;, where TYPE is WPA, WEP or nopass and HIDDEN is true for a network that does not broadcast its name. The working example above is WIFI:T:WPA;S:MyNetwork;P:hunter2;;.
What goes wrong with this format?
The format that costs people the most time, because every one of its quirks fails silently. The double semicolon at the end is mandatory and a single one does nothing. The fields are order-insensitive but the labels are case-sensitive: S: not s:. If the network name or password contains a semicolon, comma, colon, backslash or double quote, each must be escaped with a backslash. An unescaped semicolon in a password truncates it, and the phone will try to join with the wrong credentials and report a bad password. For an open network use T:nopass and omit P: entirely rather than giving an empty password. Use error correction Q or H: this code usually ends up printed small and taped to a wall, which is the worst case for a scanner.
How big does this code come out?
34 bytes at level Q gives a version 4 symbol, 33 by 33 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
- URL QR Code Generator
- QR Code for an Email Address
- QR Code for a Phone Number
- QR Code for Text
- vCard QR Code Generator