The short answer: most train e-tickets carry an Aztec code, because Aztec needs no blank margin and stays readable when squeezed onto a narrow ticket or a small screen. Some operators use QR, and a few national systems use Data Matrix-based standards. Mobile transit passes are increasingly QR or rotating codes shown live in an app.
Why rail loves Aztec
The Aztec code has one property that suits rail perfectly: it needs no quiet zone. The concentric bullseye in its centre is enough for a scanner to find and orient the code, so it can be printed right up to the edge of a small ticket — or shown on a cramped phone display — and still read cleanly. It also carries enough data to hold a signed description of the journey, so a gate or guard's reader can validate it without a live connection.
How rail tickets differ from boarding passes
| Train e-ticket | Airline boarding pass | |
|---|---|---|
| Typical format | Aztec (some QR / Data Matrix) | PDF417 print, Aztec/QR mobile |
| Validated by | Turnstile or on-board guard | Gate agent at departure |
| Reused? | Often valid for a window / return leg | Single boarding event |
| Standard | Operator / national scheme | IATA BCBP (global) |
For the symbology details behind these, see the format comparison and the airline boarding pass guide.
Turnstiles, guards and offline checks
Rail gates often have to work where connectivity is poor — underground, in tunnels, on a moving train. That favours self-contained tickets: the Aztec code carries signed journey data that the reader verifies locally, rather than phoning a server for every passenger. The trade-off is that a self-contained ticket is harder to revoke instantly, so operators lean on signatures and validity windows instead of live single-use checks.
Mobile transit passes
Phone-based fares are increasingly common on metro and bus networks. They take a few forms:
- Static QR shown from the app or wallet — simple, works offline.
- Rotating codes that refresh every few seconds, to stop one pass being shared around a group — see rotating barcode tickets.
- Contactless/NFC, which is not a barcode at all — you tap rather than scan.
When a transit barcode won't scan
Transit readers are unforgiving because the queue moves fast. The usual fixes:
- Brightness to maximum; wipe the screen.
- Show the whole code with a little margin — don't zoom until it fills the edges.
- If it's a rotating pass, present it live from the app, not a screenshot.
- Check the pass is valid for this route, zone and time — a "rejected without reason" pass is often simply out of zone or outside its window.
Step-by-step help: why won't my ticket scan.