The Duke of Kent will ride on the footplate of a heritage railway engine when he joins the Keighley & Worth Valley Railway’s 50th anniversary celebrations.

His Royal Highness became patron of the Keighley & Worth Valley Railway (KWVR) Preservation Society following a visit to the railway in 2008, and will return on October 17.

The railway is also developing a new smartphone ‘app’ to promote the attraction.

The royal visit will also mark the centenary of the restored Lancashire and Yorkshire Railway Club Carriage, which was used as a cricket pavilion before being brought back into use.

KWVR chairman Matt Stroh said: “We know that His Royal Highness is a keen railway enthusiast and we are honoured that he graciously agreed to accept this role, which we feel reflects the high standards that the railway sets itself.

“We are delighted that he will be helping us to mark our 50th anniversary and the Carriage’s centenary.”

Eric Rawcliffe, from the Lancashire and Yorkshire Railway Trust, said the duke had agreed to unveil a commemorative plaque to recognise the return of the Yorkshire Railway Club Carriage.

The 1912 carriage was built to be used exclusively by Manchester businessmen who chose to live in the Fylde coastal resorts of Blackpool, Lytham and St Anne’s. Destined for scrapping in 1951, it instead found use as a sports pavilion until 1993. It was rescued from its site which was due for housing development and members of the Lancashire and Yorkshire Railway Trust spent 18 years restoring it.

Meanwhile, visitors to the KWVR will be able to take a virtual tour through its history and landscape from the comfort of their train carriage when it launches a new smartphone app.

The group is working with software developers to create the phone app to provide passengers with an interactive guide to the railway.

It is the latest stage of a major project called Worth Exploring to provide interpretation boards and literature to help visitors understand the history of the railway and the areas the line passes through in the Worth Valley.

The project has been part-funded by Oxenhope parish council.

Mr Stroh said: “The next generation of passengers will all use smartphones and, if we do not engage with them, it will become a static exhibition.”

Keiran Pilsworth, KWVR marketing manager, said: “It is using technology from the 21st century to enhance the visitor experience to the 1950s railway.”