The average train between Ayr and Dunfermline takes 3h 13m and the fastest train takes 2h 36m. There is a train service every few hours from Ayr to Dunfermline. The journey time may be longer on weekends and holidays; use the search form on this page to search for a specific travel date.
Trains run hourly between Ayr and Dunfermline. The earliest departure is at 5:36 AM in the morning, and the last departure from Ayr is at 10:05 PM which arrives into Dunfermline at 6:50 AM. All services require a transfer at Glasgow Central and take an average of 3h 13m. The schedules shown below are for the next available departures.


2h 42m • 2 changes


3h 14m • 2 changes


2h 46m • 2 changes


2h 40m • 2 changes


2h 42m • 2 changes


3h 14m • 2 changes


2h 46m • 2 changes


2h 40m • 2 changes


2h 45m • 2 changes


2h 48m • 2 changes


2h 45m • 2 changes


3h 13m • 2 changes
Want to know about travelling from Ayr to Dunfermline? We have put together a list of the most frequently asked questions from our users such as: What is the cheapest mode of transport? What is the quickest option? How much do tickets usually cost? and many more.
No, there is no direct train from Ayr to Dunfermline. However, there are services departing from Ayr station and arriving at Dunfermline station via Glasgow Central. The journey, including transfers, takes approximately 3h 13m.
Ayr to Dunfermline train services, operated by ScotRail, depart from Ayr station.
Ayr to Dunfermline train services, operated by ScotRail, arrive at Haymarket station.
Book your Ayr to Dunfermline train tickets online with ScotRail and Cross Country.
The distance between Ayr and Dunfermline is 99.9 km. The road distance is 162 km.
You can take a train from Ayr to Dunfermline Town via Glasgow Central and Haymarket in around 3h 26m.