In 1854, plans were made to build a mountain railway from Mettupalayam to the Nilgiri Hills. However, it took the decision-makers 45 years to cut through the bureaucratic red tape and complete the construction. The line was completed and opened for traffic in June 1899. It was operated first by the Madras Railway under an agreement with the government. The Madras Railway Company continued to manage the railway line on behalf of the government for a long time until the South Indian Railway company purchased it. In 1907, the railway received four Double Fairlie locomotives to work the line. These were part of a batch built by the Avonside Engine Company in 1879 and 1880 for service in Afghanistan, but had been in store since 1887. The Fairlies continued in use until at least 1914. Initially, Coonoor was the final station on the line. In September 1908, the line was extended to Fernhill. By 15 October 1908, it was extended to Udagmandalam. These extensions from Coonoor on the same gauge over a distance of were done at a cost of Rs. 24,40,000/-.
Operators
The NMR and all of its assets, including the stations, the line, and the track vehicles, belong to the Government of India and are managed by the Ministry of Railways. The Southern Railway performs the day-to-day maintenance and management, but several programs, divisions and departments of the Indian Railways are responsible for operating, maintaining and repairing the NMR.
Rack and pinion
Between Mettupalayam and Coonoor, the line uses the Abt rack and pinion system to climb the steep gradient. The NMR is the only rack railway in India.
Rolling stock
NMR uses 'X' Class steam rack locomotives, manufactured by the Swiss Locomotive and Machine Works of Winterthur in Switzerland, on the rack and pinion section of its tracks. The X Class locomotives are six to eight decades old. These locomotives give NMR a distinct charm, taking scores of passengers to Coonoor and Udhagamandalam, crossing, 108 curves, 16 tunnels and 250 bridges. The steam locomotives can be used on any part of the line, while the diesel locomotives can operate only on the section between Coonoor and Udagamandalam. This signals the beginning of the phasing out of the steam engines. Each diesel engine weighs a little over 50 tonnes and cost Rs. 10 crore. They have pilot and primary burners. Separate tanks hold about of diesel and of furnace oil. The hauling capacity of this new engine is. It can run at a speed of on plains and at an hour climbing a gradient. The arrival of the new engines eliminated the disruptions in service that occurred frequently. The steam locomotives are marshalled at the downhill end of the train. The average gradient in this rack section is 1 in 24.5, with a maximum of 1 in 12. Between Coonoor and Udagamandalam, the train is operated by a YDM4 diesel locomotive using conventional rail adhesion principles. On this section, the locomotive is always at the Coonoor end of the train as although the line is not steep enough to need a rack rail, the ruling gradient out of Coonoor is steep at 1 in 25. Southern Railway carries out the majority of the locomotive repairs at the Coonoor shed but has rebuilt many of the steam locomotives at the Golden Rock Workshops. Many carriage repairs take place at Mettupalayam. Like the locomotives, major work on the carriages takes place at one of the larger railway workshops.
Route
The uphill journey takes around 290 minutes, and the downhill journey takes 215 minutes. It has the steepest track in Asia with a maximum gradient of 8.33%. As of 2007, a daily train crosses the rack section, which starts from Mettupalayam at 07:10 and reaches Udhagamandalam at noon. The return train starts from Udhagamandalam at 14:00, and reaches at 17:35. The train is scheduled to connect to the Nilgiri Express, which travels from Mettupalayam to Chennai via Coimbatore. A summer special service runs in April and May, starting from Mettupalayam at 09:30 and from Udhagamandalam at 12:15. Between Coonoor and Udagamandalam, four daily trains run each way. Even though the NMR supplies networked computerized ticketing systems for onward journeys, it still issues Edmondson style manual tickets for the Udhagamandalam-Mettupalayam journey to preserve its 'World Heritage Site' status. Ticket booking is similar to conventional trains and can be done via the Indian Railway website. It is advisable to book tickets well in advance, especially during peak season.
Stations
Mettupalayam has the line near to. Passengers cross the platform to board the NMR. A small locomotive shed is there and the carriage workshops for the line. Leaving Mettupalayam, the line is adhesion-worked and actually drops for a short distance before crossing the Bhavani River, after which it starts to climb gently.
Kallar is closed as a passenger station, although it is where the rack rail begins. As the train leaves the station, the gradient is 1 in 12.
Hillgrove is a block post and water stop with passenger refreshments.
Runnymede is used only as a water stop.
Kateri Road: trains no longer not stop there.
Coonoor is the main intermediate station, sited near the locomotive workshops as well as the top end of the rack rail. Trains must reverse a short distance before continuing their climb to Udhagamandalam. It is normal for the locomotive to be changed there with diesel traction, normally used for all trains to Udhagamandalam.
Wellington
Aravankadu
Ketti
Lovedale: From a short distance before Lovedale, the line descends into Udhagamandalam.
Udhagamandalam has preserved much of its equipment from the Raj. In addition to the original 1908 building, it operates a water dispenser for steam locomotives, and a weighing scale made in 1907 by Hendry Boomley & Son of Birmingham.
Coonoor station was one of two used as locations in the David Lean film A Passage to India. Coonoor station and its heritage locomotive appear in many Indian films. Wellington station finds a place in most of the films casting the Indian army or army training storyline, mainly due to the MRC Indian Army Regiment, Defence Services Staff College, the Cantonment and the Cordite Factory. Ketti station was used as the location in a Malayalam film Summer in Bethlehem. Lovedale station is featured in films including the Tamil hit, Moonram Pirai. The famous Hindi song "Chaiyya Chaiyya" from Dil Se.. was shot on the rooftop of NMR. Udhagamandalam station has featured in Tamil and other South Indian films. It is prominently featured in some Bollywood films. One of the X Class locomotives on the Nilgiri Mountain Railway was the model for Ashima in the film .
Television
In the UK, the BBC made three 2010 documentaries dealing with Indian Hill Railways, featuring NMR in the second programme. The films were directed by Tarun Bhartiya, Hugo Smith, and Nick Mattingly, and produced by Gerry Troyna. The series won the UK Royal Television Society Award in June 2010.