The Conservative member, who even took to the coal shovel during his stay, was told the railway carries more than 210,000 passengers a year, taking an estimated 40,000 cars off the A351 Corfe Castle to Swanage road.
Mr Drax, who rode a recently-restored 1940s carriage into Swanage station, was met by town mayor Ali Patrick.
“The Swanage Railway plays a vital and integral part in promoting tourism in Purbeck,” said the MP.
“Those romantic days of steam are played out every day on this scenic stretch of line which is best loved and maintained by a band of railway enthusiasts who have Purbeck’s interests at heart.”
During the day, Mr Drax rode on the footplate of the 1940s steam locomotive ‘Eddystone’, and even shovelled coal into its firebox.
He also took a tour of the Purbeck Mineral and Mining Museum next to Norden station.
Mr Drax said: “The team has worked tirelessly to provide a service for residents and tourists alike and my visit to the Swanage Railway was a highly enjoyable, informative and action-packed afternoon.
“The Swanage Railway is right at the heart of life in Purbeck and offers an unforgettable experience to tourists who come to Dorset to savour our rural culture.”
Swanage Railway chairman Peter Sills said the railway contributes £14 million a year to the local economy.
He added: “The railway also helps bring more businesses to local hotels, restaurants, bed and breakfast establishments and campsites.”