Qraft

How Just Scanning Connects You to Wi-Fi - What Happens Behind the Scenes

What "Scan to Connect" in Cafes Really Is

In many cafes and hotels, a black-and-white pattern is stuck on the table or counter, sometimes with the words "Scan to connect to Wi-Fi." When you hold up your smartphone camera, you can connect to Wi-Fi without typing a password. It seems like magic, but a clear mechanism is at work behind the scenes.

This pattern stores the three pieces of information needed to connect to Wi-Fi. They are the network name (SSID), the password, and the encryption type. Your smartphone reads these three pieces of information, automatically opens the Wi-Fi settings screen, and carries out the connection process. Instead of a person typing the password on a keyboard, the camera reads the information quickly.

The "Secret Message" Written in the Pattern

A pattern for Wi-Fi connection stores text in the format WIFI:T:WPA;S:CafeNetwork;P:coffee2026;;. Broken down, T:WPA means "the encryption method is WPA," S:CafeNetwork means "the network name is CafeNetwork," and P:coffee2026 means "the password is coffee2026."

This format is a way of writing proposed in the documentation of the scanning library ZXing, and it can be read on both iPhone and Android. When the smartphone's OS recognizes this format, it automatically opens the Wi-Fi settings screen, fills in the SSID and password, and tries to connect. All the user has to do is tap the confirmation "Connect?"

The Password Is Not Encrypted - A Fact You Should Know

Here is one important fact to keep in mind. The password stored in the pattern is not encrypted. Anyone who scans the pattern can read the password in plain text (the string as it is). That is no problem for a cafe Wi-Fi password, but if you turn your home Wi-Fi password into a pattern and post it on SNS, your password will be made public to the whole world.

You may think, "But you can't tell the password just by looking at the pattern, can you?" It is true that human eyes cannot read it, but a smartphone camera can read it right away. The password can be extracted even from a pattern that appears in a photo, so be careful not to let your home Wi-Fi pattern show up in the background of photos.

Why It Is Safer Than Typing the Password

If the password is not encrypted, why can we say that using a pattern is safer? The reason is the prevention of "shoulder hacking." When you type a password by hand in a cafe, the person in the next seat may peek at your screen. When you scan a pattern, the connection is completed without the password being shown on the screen, so you can reduce the risk of someone peeking.

Another advantage is that you can set long, complex passwords. When manual entry is assumed, passwords tend to be short and easy to remember, such as "cafe1234," but with a pattern, even a random 16-character password such as "X7k#mP9$vL2@nQ5w" puts no burden on users. The more complex the password, the lower the risk of unauthorized access.

Precautions When Using Public Wi-Fi

Behind the convenience of connecting to Wi-Fi just by scanning, there are also points to watch out for. It is important to check whether a code posted in a public place is really a legitimate one provided by that store or facility. A malicious third party may also post a fake code and lead users to an illegitimate network. When you are not sure whether the network you have connected to can be trusted, it is safer to hold off on operations that exchange important information, such as paying for purchases or logging in. An attitude of enjoying the convenience while staying aware of where you are connecting leads to safe use.

Checklist When You Cannot Connect

Sometimes you cannot connect to Wi-Fi even after scanning the pattern. Here are common causes and how to deal with them. First, check whether your smartphone's Wi-Fi is turned off. If airplane mode is on, Wi-Fi may also be disabled. Next, if the camera app does not recognize the pattern, try Google Lens or a dedicated scanner app.

If you still cannot connect, the password stored in the pattern may have been changed. Even when a cafe or hotel changes its password, the printed pattern sometimes stays the old one. Asking a staff member "Has the password changed?" is one reliable way to find out. Also, scanning may fail if the pattern is too small or the print is faded. Try scanning in a bright place from a distance of 10-20 cm.