Brief Description
General Transit Feed Specification (GTFS) is a digital exchange format initiated by Google for public transport timetables and associated geographical information, such as stop locations. It is now operated by the MobiliyData organisation (https://mobilitydata.org/). There are different versions of GTFS – for our data set with the timetables, we use GTFS Static (GTFS-S; also known as GTFS Schedule).
A GTFS Static file contains all public transport in Switzerland for a public transport timetable year (365 days from mid-December). Unlike GTFS Realtime (GTFS-RT), GTFS Static only provides static data and no real-time data. (Timetable year at öv-info.ch)
Access the Data
- https://data.opentransportdata.swiss/de/dataset/timetable-2026-gtfs2020 – Timetable current timetable year (2026)
- https://data.opentransportdata.swiss/dataset/timetable-2027-gtfs2020 – Timetable for the next timetable year (2027)
- https://data.opentransportdata.swiss/dataset/timetable-draft-gtfs – Draft timetable
Functional Description
GTFS Static is provided by means of a series of text files in ZIP format. The information contained is derived from the underlying HDRF file (https://opentransportdata.swiss/cookbook/timetable-cookbook/hafas-rohdaten-format-hrdf/). GTFS can display most, but not all, information from HRDF. This information is delivered by the individual transport companies. Each file contains information on a specific aspect of transit information such as stops (stops.txt), lines (routes.txt), trips (trips.txt), transport companies (agency.txt) and other timetable-relevant data. Some information is necessary to provide valid GTFS data, while others are optional and provide useful additional information (e.g. timetable changes on specific public holidays = calendar_dates.txt).
Due to the wide distribution of the format, there are numerous tools on GitHub for handling GTFS data, which MobilityData has collected, known as awesome-transit. In addition, opentransportdata.swiss provides specific tools for Swiss data Tools-and-more (in the section ‘For handling GTFS timetable and real-time data’).
The following diagram shows how the different files contained in GTFS relate, although not all of them are currently included for the Swiss public transport system:
In addition to GTFS-S, the following GTFS formats are made available on opentransportdata.swiss:
- GTFS Realtime (GTFS-RT) with real-time data (e.g. delays)
- GTFS real-time service alerts (GTFS-SA) with event data (e.g. closure of a stop due to an accident)
- GTFS Flex for on-demand services (addition for GTFS-S)
Technical Description
Structure of the data
Each file consists of comma-separated text and number series with fields, which together provide the information searched for. The first line contains the column names, as usual for CSV files. The individual fields in the different files are explained in detail on the official GTFS standard website: https://gtfs.org/documentation/schedule/reference/
The following files are currently available in our dataset:
- agency.txt
- calendar.txt
- calendar_dates.txt
- feed_info.txt
- routes.txt
- stop_times.txt
- stops.txt
- transfers.txt
- trips.txt
- frequencies.txt (from February 2026)
A summary of the individual files is given below, further details can be found in the Swiss GTFS profile.
agency.txt
The file agency.txt lists all the transport companies that are present in the data set. If the URL for a transport company cannot be determined, agency_url the URL of the transport company SBB.
Example:
agency_id,agency_name,agency_url,agency_timezone,agency_lang,agency_phone
"11","Schweizerische Bundesbahnen SBB","http://www.sbb.ch/","Europe/Berlin","DE","0848 44 66 88"
"65","THURBO","http://www.sbb.ch/","Europe/Berlin","DE",""
"823","Basler Verkehrsbetriebe","http://www.bvb.ch/","Europe/Berlin","DE",""
"37","Baselland Transport","http://blt.ch/","Europe/Berlin","DE",""
"827","Städtische Verkehrsbetriebe Bern","https://bernmobil.ch","Europe/Berlin","DE",""
"78","Sihltal-Zürich-Uetliberg-Bahn","http://szu.ch/","Europe/Berlin","DE",""
"88","Regionalverkehr Berne-Solothurn","http://rbs.ch/","Europe/Berlin","DE",""
calendar.txt
For each ‘service_id,’ the calendar.txt file defines the days of the week on which this ‘service_id’ normally operates (e.g. Mon-Fri). start_date and end_date correspond to the entire timetable period from one to the next timetable change (December to December). ‘1’ means that the service_id is running on the day in question, 0 means that it is not running.
In the trips.txt file, a ‘service_id’ together with a ‘route_id’ specify the days on which a specific trip will run.
Example:
service_id,monday,tuesday,wednesday,thursday,friday,saturday,sunday,start_date,end_date
"TA","1","1","1","1","1","1","1","20251214","20261212"
"TA+00000","1","1","1","1","1","1","1","20251214","20261212"
"TA+00100","1","1","1","1","1","0","0","20251214","20261212"
"TA+01000","0","0","0","0","0","0","1","20251214","20261212"
"TA+01100","0","0","1","0","1","0","0","20251214","20261212"
"TA+02000","1","1","1","1","1","0","0","20251214","20261212"
"TA+02100","0","0","0","0","1","0","0","20251214","20261212"
calendar_dates.txt
The file calendar_dates.txt defines the deviations/exceptions from the weekly pattern according to calendar.txt. These are often public holidays, but there can also be other reasons, such as planned construction work or major events.
exception_type: 1 = additionally runs on the specified date
exception_type: 2 = does not operate on the specified date
service_id,date,exception_type
"TA+00000","20260213","2"
"TA+00000","20260214","2"
"TA+00000","20260215","2"
"TA+00000","20260216","2"
"TA+00000","20260217","2"
"TA+00000","20260218","2"
feed_info.txt
The feed_info.txt file contains metadata about the record. The feed_version column specifies the version of the GTFS dataset that can be referenced by the GTFS real-time feeds.
Example:
feed_publisher_name,feed_publisher_url,feed_lang,feed_start_date,feed_end_date,feed_version
"SBB","http://www.sbb.ch/","DE","20251214","20261212","20250529"
frequencies.txt
The frequencies.txt file contains the frequency information for frequency journeys.
Example:
trip_id,start_time,end_time,headway_secs,exact_times<br>".ojp-93-1Q-Y.1.TA.1.j26","09:15:00","17:15:00","60","0"<br>".ojp-93-1Q-Y.1.TA.2.j26","13:15:00","17:00:00","60","0"<br>".ojp-93-1Q-Y.1.TA.3.j26","08:45:00","17:15:00","60","0"<br>".ojp-93-1Q-Y.1.TA.4.j26","13:15:00","17:15:00","60","0"<br>".ojp-93-1Q-Y.1.TA.5.j26","08:45:00","17:15:00","60","0"<br>".ojp-93-1Q-Y.1.TA.6.j26","09:15:00","11:45:00","60","0"
routes.txt
The routes.txt file contains the information about the lines.
The route_id column is structured as follows: <Betriebszweig>-<Liniennummer>-<Projektkurzbezeichnung>-<Linienversionsnummer>, the line number is often extended with an additional hyphen such as ‘-Y’. However, the content of the individual parts of the route_id is largely specific to the system that generates the GTFS data and is not suitable for displaying it to passengers. The route_short_name column contains the line designations relevant to passengers.
Example (S-Bahn lines ‘S10’ from different operators in lines 2-4):
route_id,agency_id,route_short_name,route_long_name,route_desc,route_type
"91-10-A-j26-1","78","S10","","S","109"
"91-10-B-j26-1","11","S10","","S","109"
"91-10-C-j26-1","65","S10","","S","109"
"91-29-j26-1","11","S29","","S","109"
"91-29-Y-j26-1","11","IC","","IC","102"
"91-46-j26-1","82","IR46","","IR","103"
"91-48-j26-1","11","RE48","","RE","106"
The columns route_desc and route_type contain the means of transport as per the table below. Our data set uses values from this widely used list of route_type in deviation from List according to standard (which knows only ten values for route_type):
| route_desc | DE | FR | IT | EN | route_type |
|---|---|---|---|---|---|
| ASC | Aufzug | Ascenseur | Ascensore | Lift / Elevator | 1303 |
| B | Bus | Autobus | Autobus | Bus | 700 |
| BP | PanoramaBus | Bus panoramique | PanoramaBus | Panorama Bus | 710 |
| BUS | Bus | Autobus | Autobus | Bus | 700 |
| CAR | Fernbus national | Bus longue distance national | Autobus nazionale a lunga percorrenza | National long-distance bus | 202 |
| CAX | Fernbus international | Bus grandes lignes international | Autobus a lunga percorrenza internazionale | International long-distance bus | 201 |
| EB | Eilbus | Bus express | Autobus espresso | Semi fast bus | 702 |
| EXB | Expressbus | Expressbus | Expressbus | Express bus | 702 |
| ICB | InterCity-Bus | Bus InterCity | Autobus InterCity | InterCity Bus | 202 |
| BN | Nacht-Bus | Bus de nuit | Bus notturno | Night Bus | 705 |
| RUB | Rufbus | Bus sur appel | Bus a chiamata | On-demand Bus | 715 |
| TX | Taxi | Taxi | Tassì | Taxi | 1500 |
| SL | Sesselbahn | Télésiège | Seggiovia | Chairlift | 1300 |
| CC | Zahnradbahn | Chemin de fer à crémaillère | Ferrovia a cremagliera | Rack-railroad / Cog Railway | 116 |
| GB | Gondelbahn | Télécabine | Ovovia | Gondola lift | 1300 |
| LB | Luftseilbahn | Téléphérique | Funivia | Cableway / Aerial Ropeway | 1300 |
| PB | Pendelbahn | Téléphérique à mouvement de va-et-vient | Funivia a movimento va e vieni | Aerial Tramway | 1300 |
| M | Metro | Métro | Metropolitana | Underground / Metro | 401 |
| FUN | Standseilbahn | Funiculaire | Funicolare | Funicular | 1400 |
| BAT | Schiff | Bateau | Battello | Ship / Boat | 1000 |
| BAV | Dampfschiff | Bateau à vapeur | Battello a vapore | Steam ship / boat | 1000 |
| FAE | Fähre | Traversier / Ferry | Nave traghetto | Ferry | 1000 |
| KAT | Katamaran | Catamaran | Catamarano | Katamaran | 1000 |
| T | Tram | Tram | Tram | Tram | 900 |
| TN | Nachttram | Tram de nuit | Tram notturno | Night Tram | 900 |
| AIR | Flugzeug | Avion | Velivolo | Airplane | 1100 |
| UUU | Unbekannte Art | Espèce inconnue | Specie sconosciuta | Unknown mode | 1700 |
| AG | Agenturzug | Train de l’agence | Treno d’agenzia | Agency Train | 117 |
| ARZ | Autoreisezug | Train d’autos accompagnées | Treno auto accompagnate | Car-carrying Train | 104 |
| AT | Autotunnelzug | Train-autos Tunnel | Treno per il trasporto di auto in galleria | Auto Tunnel Train | 104 |
| ATZ | Autotunnelzug | Train-autos Tunnel | Treno per il trasporto di auto in galleria | Auto Tunnel Train | 104 |
| E | Eilzug | Train accéléré | Treno espresso | Semi fast / non-stop Train | 103 |
| EC | EuroCity | EuroCity | EuroCity | EuroCity | 102 |
| EN | EuroNight | EuroNight | EuroNight | EuroNight | 105 |
| ES | Eurostar Italia | Eurostar Italia | Eurostar Italia | Eurostar Italia | 101 |
| EST | Eurostar | Eurostar | Eurostar | Eurostar | 101 |
| EXT | Extrazug | Train spécial | Treno speciale | Special Event Train | 117 |
| IC | InterCity | InterCity | InterCity | InterCity | 102 |
| ICE | InterCityExpress | InterCity-Express | InterCityExpress | InterCityExpress | 102 |
| IR | InterRegio | InterRegio | InterRegio | InterRegio | 103 |
| NJ | NightJet | NightJet | Nightjet | NightJet | 105 |
| P | Zug ohne Gewähr | Train non garanti | Treno senza garanzia | Train without Guarantee | 100 |
| PE | PanoramaExpress | PanoramaExpress | PanoramaExpress | PanoramaExpress | 107 |
| R | Regio | Train régional | Regio | Regio | 106 |
| RB | Regionalbahn | Réseau régional | Ferrovia regionale | Regional train | 106 |
| RE | RegioExpress | RegioExpress | RegioExpress | RegioExpress | 106 |
| RJ | Railjet | Railjet | Railjet | Railjet | 102 |
| RJX | Railjet Xpress | Railjet Xpress | Railjet Xpress | Railjet Xpress | 102 |
| S | S-Bahn | RER | Rete celere regionale | Urban Train | 109 |
| SN | Nacht-S-Bahn | RER de nuit | S-Bahn (rete celere regionale) notturna | Night-urban Train | 109 |
| TER | Train Express Regional | Train Express régional | Treno espresso regionale | Train Express Regional | 106 |
| TGV | Train à grande vitesse | Train à grande vitesse | Train à grande vitesse | Train à grande vitesse | 101 |
| ZUG | Zugskategorie unbekannt | Catégorie de train inconnue | Categoria del treno sconosciuta | Train Category Unknown | 100 |
stop_times.txt
The stop_times.txt file defines the arrival and departure times at all stops for each individual journey; it is usually the largest file for a GTFS-S delivery by far (it can be even larger if shapes.txt is delivered).
Example (one complete journey, Zürich Triemli to Zürich HB):
trip_id,arrival_time,departure_time,stop_id,stop_sequence,pickup_type,drop_off_type
"1.TA.91-10-A-j26-1.1.H","18:27:00","18:27:00","8503054:0:1","1","0","0"
"1.TA.91-10-A-j26-1.1.H","18:28:00","18:28:00","8503053:0:1","2","0","0"
"1.TA.91-10-A-j26-1.1.H","18:29:00","18:29:00","8503052:0:1","3","0","0"
"1.TA.91-10-A-j26-1.1.H","18:32:00","18:32:00","8503051:0:1","4","0","0"
"1.TA.91-10-A-j26-1.1.H","18:35:00","18:35:00","8503090:0:1","5","0","0"
"1.TA.91-10-A-j26-1.1.H","18:37:00","18:37:00","8503000:0:22","6","0","0"
stops.txt
The stops.txt file contains all stops and – if available – the exact stop or track with any sectors. Since June 2025, the ‘platform_code’ column has also been output, which contains the track or bus or tram stop. Since October 2025, the Swiss Location ID (SLOID) has also been output in the ‘original_stop_id’ column, if available. Since June 2026, the SLOID has also been in the stop_id, if available. The handling for foreign stops and stops without a parent or sloid is slightly different. The list below shows possible examples. The Didok number has also been reinserted.
Conduct
| Case | stop_id | original_stop_id |
| Unique Step SLOID | ‘ch:1:sloid:7000:6:32’ | ‘ch:1:sloid:7000:6:32’ |
| Non-unique Step SLOID | ‘ch:1:sloid:7000_gen:ch:1:sloid:7000:0:349752_pf:2A-D’ | ‘ch:1:sloid:7000:0:349752’ |
| Non-unique SLOID with special characters ‘11/12’ | ‘ch:1:sloid:6206_gen:ch:1:sloid:6206:0:11_pf:11.12’ | ‘ch:1:sloid:6206:0:11’ |
| No step SLOID | ‘ch:1:sloid:1102381_gen:missingSLOID_pf:1’ | “’ |
| No step SLOID abroad | ‘8029701_gen:missingSLOID_pf:1’ | “’ |
Example:
stop_id,stop_name,stop_lat,stop_lon,location_type,parent_station,platform_code,original_stop_id,didok
"8014228_gen:missingSLOID_pf:12","Karlsruhe Hbf","48.99351443","8.40218540","","Parent8014228","12","","8014228"
"ch:1:sloid:70985:0:313312","Tête-Noire","46.07122854","6.97499597","","Parentch:1:sloid:70985","","ch:1:sloid:70985:0:313312","8570985"
"Parentch:1:sloid:1104927","Weil am Rhein, Kant-Gymnasium","47.59530407","7.61225185","1","","","ch:1:sloid:1104927","1104927"
"ParentmissingSLOID_8302589","Venezia Mestre","45.48190300","12.23190108","1","","","missingSLOID_8302589","8302589"
"ch:1:sloid:3000_gen:ch:1:sloid:3000:501:33_pf:33AB","Zürich HB","47.37852293","8.53675303","","Parentch:1:sloid:3000","33AB","ch:1:sloid:3000:501:33","8503000"
transfers.txt
The transfers.txt file defines rules for transfers. Usually, the stops in question (from_stop_id and to_stop_id) and the time required for the transfer (min_transfer_time) are specified with transfer_type=2 (‘normal’ transfer with minimum time required according to min_transfer_time).
For all through-passages which are wings, transfer_type=4 is set. transfer_type = 4 means according to the GTFS standard that passengers do not need to change trains. This applies, for example, to coupled trains that split up (journey meetings) and thus change the trip_id but passengers can remain seated; this can be indicated with a corresponding symbol.
In addition, connections with transfer_type=1 have been guaranteed since October 2025, which means that the next means of transport will be waiting for passengers changing trains. The min_transfer_time column remains blank in these cases.
However, on instructions from the control centre, the outgoing vehicle may still not wait.
In Switzerland, the standard interchange time within a stop is set at 2 minutes. This is not visible from the GTFS file itself, but must be taken into account when routing.
Example:
from_stop_id,to_stop_id,from_route_id,to_route_id,from_trip_id,to_trip_id,transfer_type,min_transfer_time
"8501120:0:1","8501120:0:3","","","","","2","300"
"8501120:0:1","8501120:0:4","","","","","2","300"
"8501120:0:1","8501120:0:4A-D","","","","","2","300"
"8501120:0:1","8501120:0:4E-G","","","","","2","300"
"8507483:0:3","8507483:0:3","91-1-N-j26-1","91-1-N-j26-1","72.TA.91-1-N-j26-1.22.R","91.TA.91-1-N-j26-1.34.R","4",""
"8507483:0:3","8507483:0:3","91-1-N-j26-1","91-1-N-j26-1","72.TA.91-1-N-j26-1.22.R","100.TA.91-1-N-j26-1.36.R","4",""
"8507483:0:3","8507483:0:3","91-1-N-j26-1","91-11-N-j26-1","72.TA.91-1-N-j26-1.22.R","24.TA.91-11-N-j26-1.7.R","4",""
"8502282","8502282","92-634-j25-1","92-602-A-j25-1","104.TA.92-634-j25-1.1.H","114.TA.92-602-A-j25-1.1.H","1",""
"8577747","8577747","92-234-j25-1","92-235-A-j25-1","4.TA.92-234-j25-1.3.H","37.TA.92-235-A-j25-1.4.R","1",""
trips.txt
The trips.txt file contains the individual trips of the lines defined in routes.txt.
- For trains, trip_short_name includes the train number.
- A ‘trip’ according to GTFS represented in Transmodel (https://en.wikipedia.org/wiki/Transmodel) is a ‘DatedVehicleJourney’ (in OJP a ‘DatedJourney’). In Transmodel and OJP, a trip is a trip taken by the customer as returned by the Trip Planner. It consists of various trip segments, transfers and other journeys that must be travelled using different modes. In HRDF, the ‘trip’ of GTFS corresponds to the ‘Journey’ and in NeTEx to the ‘ServiceJourney’.
- The Swiss implementation uses the original_trip_id as defined for GTFS Transit (https://developers.google.com/transit/gtfs/reference). The field contains the Swiss Journey ID (SJYID), which establishes an N:1 relationship between trip_id and SJYID. The SJYID is unique only on a day basis. It is also used in GTFS-RT.
- The field ‘hints’ contains the traffic information according to the industry standard Customer information (https://www.oev-info.ch/de/branchenstandard/uebersicht). Fare codes are included as TC-<Code>.
trip_id is structured as follows: <fortlaufende Nummer in trips.txt>.<service_id>.<route_id>.<Fahrwegsnummer>.<Fahrtrichtung>
Since June 2025, composite direction texts have been displayed in the ‘trip_headsign’ field in the case of journey meetings (separation of coupled trains). For example, on the journey from Bern to Spiez, it might say ‘Brig | Zweisimmen’ if one part of the train then continues to Brig and the other continues to Zweisimmen.
Example:
route_id,service_id,trip_id,trip_headsign,trip_short_name,direction_id,block_id,original_trip_id,hints
"91-2A-Y-j26-1","TA","10.TA.91-2A-Y-j26-1.3.H","Milano Centrale","23","0","","ch:1:sjyid:100001:23-003",""
"91-46-B-j26-1","TA+3t000","1.TA.91-46-B-j26-1.1.H","Sedrun","426","0","","","2 NF"
"92-5-B-j26-1","TA+d4","10.TA.92-5-B-j26-1.2.H","St. Gallen, Rotmonten","5612","0","","","NF"
"91-1-N-j26-1","TA","57.TA.91-1-N-j26-1.22.R","Brig | Zweisimmen","4185","1","1088","ch:1:sjyid:100015:4185-001","FL"
"91-1-N-j26-1","TA","58.TA.91-1-N-j26-1.22.R","Brig | Zweisimmen","4163","1","1089","ch:1:sjyid:100015:4163-001","FL"
"91-1-N-j26-1","TA","62.TA.91-1-N-j26-1.22.R","Brig | Zweisimmen","4159","1","1094","ch:1:sjyid:100015:4159-001","FL"
"91-1-N-j26-1","TA+c9","65.TA.91-1-N-j26-1.22.R","Brig | Zweisimmen","4179","1","1077","ch:1:sjyid:100015:4179-001","FL"
"91-7C-Y-j25-1","TA+97om0","1.TA.91-7C-Y-j25-1.1.H","Neuchâtel | Fribourg/Freiburg","31110","0","3748","ch:1:sjyid:100034:31110-019","FL TC-005000"
"91-7C-Y-j25-1","TA+oot30","2.TA.91-7C-Y-j25-1.1.H","Neuchâtel | Fribourg/Freiburg","31112","0","3747","ch:1:sjyid:100034:31112-020","FL TC-005000"
frequencies.txt
The frequencies.txt file will be provided from February 2026 and contains frequency journeys typical of mountain lifts or railways (e.g. one journey per minute for chairlifts).
Here is a GTFS test file containing frequency runs: gtfs_fp2026_frequencies.zip
Further test data are available here: gtfs_fp2026_20260126_mit-frequencies_v2.zip
Example:
trip_id,start_time,end_time,headway_secs,exact_times
"1.ojp-93-264-0.1.TA.1.j26","08:30:00","17:00:00","60","0"
"1.ojp-93-264-0.1.TA.2.j26","09:00:00","16:30:00","60","0"
"1.ojp-93-264-0.1.TA.3.j26","08:30:00","18:00:00","60","0"
"1.ojp-93-264-0.1.TA.4.j26","08:30:00","17:30:00","60","0"
"1.ojp-93-264-0.1.TA.5.j26","09:00:00","16:00:00","60","0"
shapes.txt
At present, we are deliberately not using the shapes, as we are not currently receiving them from the systems we supply. We tried to generate them from the geometry, but the quality was not satisfactory. Routes are an issue on the SKI roadmap but it will take some time.
We will occasionally check if we can make the shapes better. At the moment, we would be working on the basis of OpenStreetMap (OSM). This means that the shapes are then also subject to the OSM license.
With software like pfaedle, anyone can create shapes themselves: ad-freiburg/pfaedle: Precise map matching for public transit feeds. Generate high-quality GTFS shapes from OSM data.
Days of service and calendar days in GTFS-S and GTFS-RT
The start_day in GTFS-S is the start service day for the service interval. This means times >24:00 can occur because journeys of means of transport that start after midnight (i.e. as early as the next calendar day) still belong to the same operating day.
There is no specific information for the operating day in GTFS-RT; the StartDate is always the calendar day there. The same journey can therefore depart at 24:47:00 in GTFS-S, but have a startTime of 00:47:00 in GTFS-RT.
Stability of identifiers between versions of the GTFS static file
GTFS Static is regenerated twice every week. Therefore, the service_id and the trip_id may not be the same.
New GTFS Static File Deployment Cycle
A new version of the HRDF data (basis for GTFS-S) is created on Tuesdays and Fridays; 1-2 working days later, between 9am and 10am, the GTFS statistics based on this will be published (see table below).
The corresponding GTFS RT feed will be activated at 3pm on the same day.
Please note: No updates are made on public holidays (e.g. Easter Monday, Whit Monday etc.).
| Creation of HRDF | Publication GTFS-S | Activation of GTFS-RT |
|---|---|---|
| Friday | Monday between 9 a.m. and 10 a.m. | Monday 3 p.m. |
| Tuesday | Thursday between 9 a.m. and 10 a.m. | Thursday 3 p.m. |
In the event of a disruption: The GTFS Static dataset will be published as soon as possible, followed by GTFS Realtime approximately 5-6 hours later, but no later than 6pm of the same day. If this is not feasible, the new data will be activated in GTFS Realtime the following day.
Example: The new GTFS static data could only be published in the afternoon. The GTFS real-time data will be activated the next day at around 09:00.
Further information
Matching GTFS – HRDF
The trip_id has nothing to do with the HRDF data. The assignment between HRDF and GTFS journeys is not quite 1:1 because the journey ID (= journey number) does not have to be unique within an HRDF data record. The HRDF feed that is one day old (e.g. 2025-08-13) always matches the GTFS feed (e.g. 2025-08-14)
However, you can find the right journey with the help of stops and stopping times as follows:
The trip.txt contains the trip_short_name, in the following example 25358:
route_id,service_id,trip_id,trip_headsign,trip_short_name,direction_id,block_id,original_trip_id,hints
"91-30-B-j25-1","TA+7ma70","79.TA.91-30-B-j25-1.32.R","Cadenazzo","25358","1","","ch:1:sjyid:100001:25358-001",""
This corresponds to the journey number (external train number) in the *Z line of the FPLAN file:
*Z 025358 000011 103 % -- 39759342469 --
*G S 8301030 8505404 %
*A VE 8301030 8505404 755971 %
*A X 8505410 8505410 755971 %
*A X 8505405 8505405 755971 %
*I JY 000011968 %
*I hi 8301030 8505404 000011847 %
*L 30 8301030 8505404 %
*R H %
8301030 Gallarate 00819 %
8301145 Besnate 00824 00825 %
8301144 Mornago-Cimbro 00829 00830 %
8301143 Ternate-Varano Borgh 00835 00836 %
8301142 Travedona-Biandronno 00839 00840 %
8301141 Besozzo 00844 00845 %
8301140 Sangiano 00850 00851 %
8301118 Laveno-Mombello 00856 00901 %
8301113 Luino (I) 00915 00918 %
8505874 Colmegna 00922 00922 %
8505861 Maccagno 00925 00925 %
8505862 Pino-Tronzano 00930 00930 %
8505408 Ranzo-S. Abbondio 00934 00934 %
8505410 Gerra (Gambarogno) 00935 00935 %
8505407 S. Nazzaro 00940 00940 %
8505406 Magadino-Vira 00946 00946 %
8505405 Quartino 00949 00949 %
8505404 Cadenazzo 00956 %
Since, as mentioned, the journey number does not have to be unique within an HRDF feed, the stopping times and stop_ids of the journey from stop_times.txt should also be used for assignment. In the example of HRDF (top) and GTFS (below), by way of example, the departure and destination lines are marked. The times match, as required to ‘match’ two journeys:
trip_id,arrival_time,departure_time,stop_id,stop_sequence,pickup_type,drop_off_type
"79.TA.91-30-B-j25-1.32.R","08:19:00","08:19:00","8301030","1","0","0"
"79.TA.91-30-B-j25-1.32.R","08:24:00","08:25:00","8301145","2","0","0"
"79.TA.91-30-B-j25-1.32.R","08:29:00","08:30:00","8301144","3","0","0"
"79.TA.91-30-B-j25-1.32.R","08:35:00","08:36:00","8301143","4","0","0"
"79.TA.91-30-B-j25-1.32.R","08:39:00","08:40:00","8301142","5","0","0"
"79.TA.91-30-B-j25-1.32.R","08:44:00","08:45:00","8301141","6","0","0"
"79.TA.91-30-B-j25-1.32.R","08:50:00","08:51:00","8301140","7","0","0"
"79.TA.91-30-B-j25-1.32.R","08:56:00","09:01:00","8301118","8","0","0"
"79.TA.91-30-B-j25-1.32.R","09:15:00","09:18:00","8301113","9","0","0"
"79.TA.91-30-B-j25-1.32.R","09:22:00","09:22:00","8505874","10","0","0"
"79.TA.91-30-B-j25-1.32.R","09:25:00","09:25:00","8505861:0:2","11","0","0"
"79.TA.91-30-B-j25-1.32.R","09:30:00","09:30:00","8505862:0:1","12","0","0"
"79.TA.91-30-B-j25-1.32.R","09:34:00","09:34:00","8505408:0:1","13","0","0"
"79.TA.91-30-B-j25-1.32.R","09:35:00","09:35:00","8505410:0:1","14","0","0"
"79.TA.91-30-B-j25-1.32.R","09:40:00","09:40:00","8505407:0:1","15","0","0"
"79.TA.91-30-B-j25-1.32.R","09:46:00","09:46:00","8505406:0:2","16","0","0"
"79.TA.91-30-B-j25-1.32.R","09:49:00","09:49:00","8505405:0:1","17","0","0"
"79.TA.91-30-B-j25-1.32.R","09:56:00","09:56:00","8505404:0:1","18","0","0"
Further links
- Official website of the GTFS standard (in English)
- Online meeting on 22 May 2025 (in German): Timetable data in the check (comparison of three formats: GTFS, HRDF and NeTEx)
- Online meeting on 13 November 2023 (in German): How GTFS data feeds can sustainably contribute to the improvement of public transport
#AutoTranslate
