How full is the train?

Method

Where the numbers come from

The basis is the occupancy forecast on opentransportdata.swiss. It is republished every night and covers roughly the next three months: every train of SBB, BLS, Thurbo, SOB and Zentralbahn (zb), section by section (stop → next stop), with a forecast for 1st and 2nd class.

It has only three levels: many seats free, few seats free and standing room only (plus “unknown”). These are the railways’ predictions, not counts; the dataset does not describe how they are made.

How we calculate

  • Shares by travel time. Each section counts with its scheduled duration until the next departure (including the stop). A train’s last section has no next departure and counts as 3 minutes. “Unknown” is left out of the denominators.
  • Weekday and hour come from the operating day and the section’s departure time. Patterns use four whole weeks from today, so every weekday counts equally.
  • Routes. For the 100 stations with the most departures we show every direct train to the other stations on that list (at least 4 a day). What counts is the fullest section between start and destination. Durations run to the train’s next departure at the destination (including the stop) and are approximate; they are missing where the train terminates.
  • Calmer alternative. For trains with “few seats” or “standing only” we name the nearest direct departure on the same route within 60 minutes with a lower level.
  • Standing-room chart. Minutes of “standing only” in 2nd class, averaged over all runs of a train in the next seven days. “Between A and B” names the first and the last affected section; there may be seated sections in between.

Train formation and seats

Each morning we query the train formation (API v2, formations_full) for the day’s ~150 fullest trains and the trains in the chart. It only covers the current day, and not every train gets an answer (for example when the railway’s systems disagree on the number of cars). Seats come from the vehicle records; sectors, car numbers, family zones, bike hooks and wheelchair spaces come from the formation short text shown on platform displays, because the vehicles’ own fields for these are empty in practice. A car spanning two sectors counts toward the first one in seats per sector.

We deliberately do not turn seats and forecast into passenger numbers: the forecast is a level, not a count.

Line names

The forecast only contains train numbers; its line and journey fields are literally the string “null”. Line names such as IC1 or S3 are therefore taken from the last weeks of actual data. With the timetable change on 13 December 2026 about 5% of train numbers in the forecast are new; they have no line name, and some names may be wrong until new actual data is in.

Archive

Every downloaded forecast is kept as a compact Parquet file (about 22 MB per day). The file is republished every night, but the forecast inside carries its own creation date, which can be older; that date is shown as “issued”. Once two different forecast versions exist, the home page compares them for the same trains and sections.

Open questions and limits

  • The further away a day, the calmer the forecast looks. Whether that is season and holidays or the railways being more cautious about distant days, we can only judge once several forecasts are archived.
  • Other railways (e.g. RhB, MGB, RBS), buses and trams are not covered.
  • Short-notice events (disruptions, big events, replacement buses) are only partly reflected in a forecast made weeks ahead.

Sources and licence

Data: opentransportdata.swiss (occupancy forecast; train formation, published by SBB; actual data), under the opentransportdata.swiss terms of use. Our analyses are available as JSON under “Data” (CC BY 4.0, credit: Webcracy.ch, data: opentransportdata.swiss).