Making a QR code for your Wi-Fi
Last updated 16 September 2026
A Wi-Fi QR code lets someone join your network without you reading out a password. They point a phone camera at the code, tap the prompt, and they are on. No typing, no spelling the password twice, no "is that a capital I or a lowercase L".
This is one of the few QR uses where the code genuinely beats the alternative. A guest network password read aloud is a bad experience for everyone.
What goes into the code
The payload is not a URL. It follows a format phones recognise, and it looks like this:
WIFI:T:WPA;S:MyNetwork;P:secret123;;
Broken down:
- T is the security type. WPA covers WPA, WPA2 and WPA3, which is nearly every home and office network. WEP is the old broken one. nopass is for open networks with no password.
- S is the network name, the one that shows up in the list when you look for Wi-Fi.
- P is the password itself.
- The two semicolons at the end are required. It is not a typo.
The part that catches everyone
Certain characters have to be escaped, because they mean something in the format. If your password contains one of these and the code was built by simple string joining, the code will fail or present the wrong password:
- Backslash
\becomes\\ - Semicolon
;becomes\; - Comma
,becomes\, - Colon
:becomes\: - Double quote
"becomes\"
A password like open;sesame has to appear in the payload as open\;sesame. Get this wrong and the phone will try to join with the wrong password, fail, and give the person no useful error.
The generator here handles this for you. It is worth knowing why, because if you build a Wi-Fi code somewhere else and it does not work, this is usually the reason.
Hidden networks
If your network does not broadcast its name, add H:true to the payload. Phones will then look for it by name instead of waiting to see it appear in a scan. Without that flag, the code will fail on a hidden network even though the name and password are right.
Printing it
Wi-Fi codes are usually scanned at close range, so they do not need to be huge. Something around 3 to 5cm square is comfortable. The main risk is placement: do not put it where it will be in shadow, behind glass that reflects, or somewhere guests cannot comfortably hold a phone.
A common good spot is the wall next to the router, or a card on the table in a guest room. Some people put it on the back of a menu, which works well until the menu is replaced.
A word on sharing
The password is inside the code, in plain text. Anyone who scans it gets the password, and anyone can decode a printed code with a scanner app. That is the whole point, but it means a Wi-Fi QR code is a public password. Do not put one where people you would not trust can photograph it, and change the password if the code ends up somewhere it should not have.
If you want to limit what guests can reach, use your router's guest network feature and put the code on that. Then the code can be as public as you like.