Where's the bus?

The MBTA and the Massachusetts Department of Transportation have released a real-time feed of the locations of MBTA buses on several routes. Many of the more heavily traveled routes are available, and the MBTA expects all bus routes to be available by the end of the summer. New routes will be automatically added here as they become available.

This is a little mashup which takes that real-time data and plots it on Google Maps. Choose a bus route from the pull down menu below and markers will appear with the latest locations of its buses. Markers will update with the latest information from the T every 10 seconds. Click on a bus stop marker to see predictions for when the next bus will arrive.

It is built in about 250 lines of JavaScript. It is hosted on top of Google App Engine, although this version of the site no longer uses GAE for anything other than serving the HTML files. This version of the site is using ProximoBus alternative API to get the data from the MBTA. Source code is available on GitHub.

If you have any questions, comments, or pretty stylesheets, please feel free to email or tweet them to me.

The original version of this site went up on 14 November 2009, one day after the MBTA first made this data available. It was updated with additional bus routes on 4 June 2010, and was largely rewritten to take advantage of the Google Maps v3 API and ProximoBus on 6 June 2010. Markers for stops and predictions for the next bus arrival were added on 22 June 2010. Many more routes were added 27 July 2010 and "Inbound" and "Outbound" were replaced with the terminal stations, making the code much more robust. In addition, the map now zooms in or out to show the entire bus route.

Joe Shaw