PNR Status Β· Live Train Status Β· Passenger Names Β· Seat Availability β all from your terminal, with a single command.
Tired of opening the IRCTC website or a mobile app just to check your PNR or train status? TrainTrack gives you all the train information you need right from your terminal β no app required.
| Feature | Description |
|---|---|
| π« PNR Status | Train, class, berth, fare, chart status β everything |
| π€ Passenger Names | Real name (masked before chart, full after) |
| π Live Train Status | Current location + per-station delays |
| π Trains Between Stations | All trains between any two stations |
| πΊ Seat Availability | Availability by date and quota |
| π Station Code Helper | Quick reference for common station codes |
curl -fsSL https://raw.githubusercontent.com/Saurabh-gzp/TrainTrack/main/install.sh | bash
β οΈ After installing, fully restart Termux (close the app completely and reopen it) so the custom launch command gets picked up.
Or manually:
git clone https://github.com/Saurabh-gzp/TrainTrack.git
cd TrainTrack
python3 traintrack.pyRequirements: Only Python 3.6+. No
pip install. No dependencies.
python3 traintrack.pyOr, if you set a custom command during install (e.g. train):
train 1. PNR Status (+ Names) β everything in one place (recommended)
2. Live Train Status
3. Trains Between Stations
4. Seat Availability
5. PNR Names (IRCTC - masked)
6. Station Code Helper
7. Change Launch Command β set your own command name
0. Exit
Run option 7 from the menu and enter any name (e.g. train).
After that, just typing train launches TrainTrack from anywhere.
Option: 1
10-digit PNR number: 2954982721
PNR Number : 2954982721
Train : 15708 - ASR KIR EXPRESS
Class : 2A
Booking Fare : Rs.2015
PASSENGER NAMES:
#1: CHAxxxx xxxxx (age 33, Male) | CNF/A1/24/SU
Option: 2
Train number: 15708
Journey date (YYYYMMDD): 20260814
Train : ASR KIR EXPRESS
Status : Departed Sabzi Mandi
Location : lat=29.06, lon=77.01
| Data | Source |
|---|---|
| PNR + Live Status | api.trackmytrain.co.in |
| Passenger Names | www.rr.irctctourism.com |
| Seat/Berth | www.ixigo.com |
| Trains Between | erail.in |
Q: Why does the passenger name show as "CHAxxxx xxxxx"? A: Indian Railways masks the name before chart preparation (privacy rule). Once the chart is prepared (~4 hours before departure), the full name is shown. This is the same across all apps.
Q: Does it work on Termux?
A: Yes, 100%. Just run pkg install python, then run the install command.
Q: Do I need an API key? A: No. Everything is ready out of the box.
Q: What happens with an invalid PNR? A: You'll see an "Invalid PNR" error. The PNR must be 10 digits.
- The tool only fetches public enquiry data
- It does not send any login or password
- It does not store any data (fully stateless)
PRs welcome! Open an issue if you'd like a new feature.
MIT β free for everyone.
β If you like this repo, please give it a star! Stars help more people discover it.
