Blog Wi-Fi & contact cards

Wi-Fi QR codes: the correct payload format (and the mistakes that break it)

The exact WIFI: payload syntax, escaping rules for passwords with special characters, hidden networks and security types — plus why iOS and Android sometimes disagree.

A Wi-Fi QR code is the most useful thing you can print for guests: one scan joins the network, no password typing, no spelling out a 20-character key. It is also the payload people most often get wrong, because a single unescaped character breaks it silently.

The payload format

Wi-Fi codes use a de-facto standard that Android, iOS and most scanners understand:

WIFI:T:WPA;S:NetworkName;P:password;;;
  • T: security type — WPA, WEP or nopass. Modern WPA2 and WPA3 networks both use WPA.
  • S: the SSID, exactly as broadcast (case-sensitive).
  • P: the password. Omit for open networks.
  • H:true optionally marks a hidden network.
  • The payload ends with two semicolons: one closes the last field, one terminates the record.

Escaping: the part that actually breaks

The payload is a semicolon-delimited string, so any ;, ,, :, \ or " inside the SSID or password must be backslash-escaped:

Character In the payload
; \;
, \,
: \:
\ \\
" \"

A password like coffee;2026 must become coffee\;2026. Without the backslash, the scanner reads the password as coffee and appends a stray field, which fails on both Android and iOS.

This is exactly the kind of detail a generator should handle for you — QRify's Wi-Fi mode escapes automatically, so you type the raw password and it builds the payload.

SSID rules

  • The SSID is case-sensitive and includes spaces. Cafe Guest is not cafe guest.
  • Non-ASCII SSIDs (accented letters, Cyrillic, Chinese) must be UTF-8. Some older Android versions mis-handle these; if your network name has non-Latin characters, test on an older device.
  • Hidden networks need H:true; without it the phone may not even try.
  • WPA3-only networks: use T:WPA. Most scanners fall back gracefully, but devices from before 2019 will fail to join — that is a device limitation, not a payload problem.

Security type

Value Meaning
WPA WPA, WPA2, WPA3, WPA2/WPA3 mixed
WEP Legacy WEP (avoid — it is trivially broken)
nopass Open network, no password

Do not use WPA2 as the value. Some scanners accept it, many do not; the canonical value is WPA.

Where to place the code

  • Guest room or café table: 3–4 cm square, level M.
  • Reception desk: 3 cm, printed on matte stock or a small stand.
  • Office wall: 5 cm, because people scan it from further away.
  • Sticker on a router: 2 cm is enough but the router is usually in a cupboard, so add a second copy where guests actually stand.

Glossy lamination is the enemy here: a specular reflection on a laminated card under café lighting is one of the most common reasons a Wi-Fi code "works at home but not here".

Changing the password

Static Wi-Fi codes contain the password. When it changes, every printed code must be replaced. If you rotate guest passwords weekly, print the code on a card you can reprint cheaply, or use a captive portal instead — a dynamic redirect service would work, but it introduces a dependency that QRify deliberately avoids.

When the scan succeeds but the join fails

  1. The SSID differs in case or has a trailing space.
  2. The password contains an unescaped special character.
  3. The network is hidden and the code does not set H:true.
  4. The device is 2.4 GHz only and the network is 5 GHz only.
  5. The access point has MAC filtering or a captive portal that blocks direct joins.

Test with the built-in scanner in the camera app rather than a third-party app: it shows the parsed SSID before joining, which tells you immediately whether the payload is correct.

Frequently asked questions

What is the correct Wi-Fi QR code format?
WIFI:T:WPA;S:SSID;P:password;; — with T: set to WPA, WEP or nopass, and any special characters in the SSID or password escaped with a backslash.
Why does my Wi-Fi QR code not connect?
The three usual causes are an unescaped ; or , in the password, an SSID that does not match exactly (including case), and a hidden network without H:true.
Can I put a Wi-Fi QR code on a router?
Yes, and it is a good place for a backup copy — but make a second code where guests actually stand, since routers tend to live in cupboards.
Is a Wi-Fi QR code safe?
It shares the network password with anyone who scans it, so treat it like a written password. Use a separate guest network with a rotating password rather than your main network.

A small, independent studio project built for people who need a code that actually scans. کنوین

Back to the blog