Skip to main content
Colour Stripe`

Here you will find documentation about the Transport for NSW APIs and datasets:

General Transit Feed Specification (GTFS) and GTFS-Realtime (GTFS-R)Reference Tables
Sydney MetroTrains
BusesFerries
Light RailTransXChange (TXC)
Trip PlanningRoads Real-time Data and Live Traffic
Location Facilities, Transport Operator, Loading Zone, Off-street ParkingGTFS Studio User Guide

General Transit Feed Specification (GTFS) and GTFS-Realtime (GTFS-R)

This dataset contains the main static (no real-time) public transport information in General Transit Feed Specification (GTFS) format for all operators. Most of the time we will refer to this as the "GTFS bundle" and can be accessed via API or downloaded as a zip file. It includes static timetables, stop locations, and route shape information as well as regional routes, trackwork and transport routes not available in real-time feeds. The 'Timetables Complete GTFS' dataset contains the following files:

  • agency.txt - list of transit agencies that provide the data in this feed
  • calendar.txt - dates for service IDs used by each trip
  • calendar_dates.txt - exceptions for the service IDs defined in the calendar.txt file
  • routes.txt - transit routes. A route is a group of trips that are displayed to customers as a single service
  • shapes.txt - rules for drawing lines on a map to represent a transit organisation's routes
  • stop_times.txt - times that a vehicle arrives at and departs from individual stops for each trip
  • stops.txt - individual locations where vehicles pick up or drop off passengers
  • trips.txt - trips for each route. A trip is a sequence of two or more stops that occurs at a specific time

The 'Public Transport - Timetables - For Realtime' dataset also contains static timetables, stop locations and route shape information in GTFS format but only for operators that support real-time data. We might sometimes refer to this dataset as the "real-time GTFS bundle". You can match up this dataset with our real-time APIs to come up with a complete view of both static and real-time data. This dataset can be accessed via the API, which is split by endpoints for each mode of transport - buses (a bundle with all operators and also individual ones for each), ferries, light rail, NSW TrainLink and Sydney Trains.

When you call the API, the response will be returned in binary format. You need to use a .proto file to convert the data into readable format and apply our modifications. To learn more about protocol buffer files go to https://gtfs.org/extensions/#__tabbed_1_2

  • TfNSW proto file - describes the extension 1007 that includes TfnswVehicleDescriptor and CarriageDescriptor (***after downloading please change the file extension to ".proto", ie. remove "_.txt")
  • Proto File for NLR - download the proto file for Newcastle Light Rail (***after downloading please change the file extension to ".proto", ie. remove "_.txt")

Full Documentation

Datasets:

  • Timetables Complete GTFS - the full GTFS bundle
  • Public Transport – Timetables – For Realtime - static GTFS data for operators and services that support realtime data
  • Public Transport – Realtime Trip Update - stop time updates for active trips
  • Public Transport – Realtime Vehicle Positions - current vehicle positions in GTFS-R format
  • Public Transport – Realtime Alerts - realtime alerts at either the stop, trip, or service line level

Reference Tables

Reference Tables dataset and documentation (includes overlapping agencies in GTFS feeds and NSW Trains services)

Sydney Metro

Sydney Metro GTFS and GTFS-R data is included in our feeds.

Full Documentation

Trains

Both Sydney Trains and NSW Trains data is included in the Trains GTFS bundle. However, you should use the NSW Trains feed for trains running beyond the intercity network area (bordered by Goulburn, Bathurst, Scone, Dugong and Nowra).

Full Documentation

Datasets

  • Public Transport – Timetables – For Realtime - static GTFS data for operators and services that support realtime data
  • Public Transport – Realtime Trip Update - stop time updates for active trips
  • Public Transport – Realtime Vehicle Positions - current vehicle positions in GTFS-R format
  • Public Transport – Realtime Alerts - realtime alerts at either the stop, trip, or service line level

Buses

The purpose of the GTFS Bus Timetable Feed is to publish in advance the schedules and route information of Bus services operated under the Sydney Metropolitan and Outer Sydney Metropolitan Bus Services Contracts (‘O/SMBSC’), plus Sydney NightRide and Sydney Olympic Park Major Events Bus Contracts.

Full Documentation

Datasets

  • Public Transport – Timetables – For Realtime - static GTFS data for operators and services that support realtime data
  • Public Transport – Realtime Trip Update - stop time updates for active trips
  • Public Transport – Realtime Vehicle Positions - current vehicle positions in GTFS-R format
  • Public Transport – Realtime Alerts - realtime alerts at either the stop, trip, or service line level

Bus Contract Regions

Refer to the shape files in the Metro Outer Metro Bus Contract Boundaries dataset to map the latest Metro / Outer Metro Bus contract boundaries.

Ferries

The Sydney Ferries GTFS bundle is sourced directly from Harbour City Ferries.

Full Documentation

Datasets

  • Public Transport – Timetables – For Realtime - static GTFS data for operators and services that support realtime data
  • Public Transport – Realtime Trip Update - stop time updates for active trips
  • Public Transport – Realtime Vehicle Positions - current vehicle positions in GTFS-R format
  • Public Transport – Realtime Alerts - realtime alerts at either the stop, trip, or service line level

Light Rail

Light Rail GTFS data feeds are supplied separately for Inner West, CBD and Southeast, and Newcastle Light Rail.

Full Documentation

Datasets

  • Public Transport – Timetables – For Realtime - static GTFS data for operators and services that support realtime data
  • Public Transport – Realtime Trip Update - stop time updates for active trips
  • Public Transport – Realtime Vehicle Positions - current vehicle positions in GTFS-R format
  • Public Transport – Realtime Alerts - realtime alerts at either the stop, trip, or service line level

TransXChange (TXC)

TransXChange is an implementation of the Transmodel open standard for public transport information. Read further information about TransXChange. The information provided in TXC format includes route, timetable and stop/station/wharf information.

Full Documentation

Datasets

  • Public Transport - Timetables - Complete - TransXChange

Trip Planning

The API allows users to search for trips, stops, service alerts and places of interest using the following five request types / endpoints:

  1. Stop Finder API: Provides capability to return all NSW public transport stop, station, wharf, points of interest and known addresses to be used for auto-suggest/auto-complete (to be used with the Trip planner and Departure board APIs).
  2. Trip Planner API: Provides capability to provide NSW public transport trip plan options, including walking and driving legs, real-time and Opal fare information.
  3. Departure API: Provides capability to provide NSW public transport departure information from a stop, station or wharf including real-time.
  4. Service Alert API: Provides capability to display all public transport service status and incident information (as published from the Incident Capture System).
  5. Coordinate Request API: When given a specific geographical location, this API finds public transport stops, stations, wharfs and points of interest around that location.

Full Documentation

Datasets

  • Trip Planner API

Roads Real-time Data and Live Traffic

For roads data please visit the Live Traffic NSW website or use an alternative service such as Google Maps. Live Traffic APIs are also available via the datasets below.

The Roads Realtime API was decommissioned on July 1 due to RMS no longer providing the necessary data and support.

For historical data please have a look at the Historic Roads Travel Time Data dataset below. ***We are working on a more extensive historical data sample of Roads data.

Full Documentation

Datasets

  • Live Traffic Hazards - Information on incidents, fires, floods, alpine conditions, major events and roadworks
  • Live Traffic Cameras - Image URL, GPS coordinates, and view description of traffic cameras
  • Live Traffic Site Status - Current status of the Live Traffic NSW website
  • Historic Roads Travel Time Data (TTDS)

Location Facilities, Transport Operator, Loading Zone, Off-street Parking

Full Documentation

  • Please refer to the Data Dictionary for the Location Facilities, Transport Operator, Loading Zone, Off-street Parking datasets

Datasets

  • Roads - Static - Loading Zones - Kerbside
  • Roads - Static - Parking - Off-Street
  • Public Transport - Facilities & Operators

GTFS Studio User Guide

GTFS Studio is designed to help manage, view, query and extract GTFS and GTFS-R data with a simple to use interface. GTFS data can be a difficult data source to understand and work with, especially for users new to GTFS. This system was built to make GTFS data easier to read and understand for all data consumers.

Full Documentation