Using the metro in China with your phone (or your card)
Photo: Kaihao Zhao / Unsplash
Every big Chinese city has a good metro, and most have built their networks in the last twenty years, so they're new, clean and cheap. If you've used Seoul or Tokyo, you'll feel at home: frequent trains, platform screen doors, station names and announcements in English. A typical ride costs a few yuan.
The only hurdle is the gate. You now have three ways through it, and which one is best depends on the city.
Three ways through the gate
| Method | Good for | Watch out for |
|---|---|---|
| Transit QR code in Alipay | Almost every city with a metro | Each city's code has to be turned on |
| Tapping a contactless foreign card | Beijing, Shanghai, and a growing list of others | Not every gate or city yet; your bank's foreign fee |
| Single ticket from a machine or counter | A one-off ride, or when your phone is flat | Queues at busy stations; some machines prefer cash or QR |
Setting up the Alipay transit code
- Link a card first. The transit code charges the card in your Alipay wallet. If you haven't set that up, see Alipay with a foreign card.
- Find the code. In Alipay, search "Transport" or the city's name plus "metro". You'll see the city's ride code.
- Turn it on for your city. Agree to the terms. Some cities ask you to confirm your passport details once.
- Test it before the gate. Open the code on the concourse, not with a queue of commuters behind you.
- Scan in and scan out. Hold the code face down over the reader at the entry gate, and again when you leave. The fare is charged after you exit.
The most common mix-up: you arrive in a new city, open the code, and it's still set to the last one. Switch cities in the app when you get off the train, before you reach the gate.
Just tapping your card
This is the change I'd most like visitors to know about. If you're used to tapping a card in London or Sydney, a few Chinese cities now work the same way.
Beijing's city government reported that from September 2024 Visa and Mastercard contactless cards worked at subway gates, and that from June 2025 JCB and American Express were added, across all lines and fare gates, including the two airport express lines. It also said cards from more than 130 countries and regions had been used on the system since the first rollout. No app, no ticket.
In Shanghai, the city's 2025 service guide for international visitors says contactless UnionPay, Visa and Mastercard cards can be tapped at the gates of more than 500 stations. The official Metro Daduhui app and the city's Suishenxing app also take foreign cards if you'd rather use a QR code.
My take: in Beijing and Shanghai, tapping is now the easiest option for a short trip. Use the same card to exit that you used to enter, or the system can't work out the fare. Elsewhere, look for card logos on the gate readers; if there aren't any, use Alipay.
At the station, in order
- Security check. Nearly every station has one at the entrance. Your bag goes through an X-ray scanner, and staff may ask you to sip from a drink bottle. It takes seconds unless it's rush hour.
- Gate. QR code, card, or ticket. Gates with a wide aisle are for luggage and wheelchairs.
- Platform. Signs give the line number, colour and the terminal station. Check the direction by the last stop, as you would in Paris.
- Transfers. Usually free within the system and well signed in English. Some big interchange stations involve a long walk.
- Exit. Exits are numbered or lettered. Your hotel or map app will tell you which one; picking the right exit can save ten minutes above ground.
When it goes wrong
- The gate beeps and stays shut. Check the code is for this city and that your phone screen is bright enough. If it still fails, go to the service counter; staff can let you through and fix the fare.
- Your card was declined at the gate. Your bank may be blocking foreign transactions. Switch to Alipay, and call or message your bank later.
- You entered with one method and want to leave with another. Don't. Exit with the same one, or ask staff.
- Your phone dies. Buy a single ticket at the machine or counter. This is one reason I always carry a little cash and a power bank; see the power bank rules before you pack one.
Quick answers
Is it busy?
At rush hour, very. Roughly 7:30 to 9:30 and 5:30 to 7:30 on weekdays, lines into business districts are packed. With big luggage, travel outside those times or take a DiDi.
Do the trains run late?
Most systems close around 11pm, give or take, and times vary by line. Check the last train for your line in the station or your map app.
Can I use the same code for buses?
Usually, yes. In most cities the Alipay ride code works on city buses too.
Does the metro go to the airport and the train stations?
In most big cities, yes. For the station itself, see our guide to high-speed trains.
Sources: Beijing government: subway tap-and-go with five card brands (Jun 2025) · China Daily: international cards on the Beijing subway · Shanghai government: metro access guide for visitors (Oct 2025) · Shanghai government: metro stations accept foreign bank cards (Apr 2024)
If something here has changed, email me. I re-check every guide and update the date at the top.
Written by David, who lives in China. About me