Prestonpans Railway Station (referred to in Gaelic as Na Panaichean:) is located on the southern margin of the town, a half-mile (0.8 km) south southeast of centre and a mile (1.5 km) northwest of Tranent in East Lothian. This station was opened in 1846 by the North British Railway and now lies on the East Coast Main Line, although only North Berwick service stop here. Its original buildings remain on the northernmost of its two platforms. A set of murals depicting local scenes by artist Adele Conn were installed in 2010. Now operated by ScotRail, Prestonpans Railway Station is unstaffed and is used by more than 250,000 passengers per annum (2014). It is preceded by Longniddry Railway Station, 3¾ miles (6 km) to the east northeast, and followed by Wallyford, 2 miles (3 km) to the west southwest.
Branch lines once diverged from the Main Line near here to service various coal mines, however these at all closed by the 1980s. One line remained, delivering coal to Cockenzie Power Station, but this closed in 2013.