ALMOST as soon as an engine shed in Darlington was built in 1844, it was redundant. Now, after decades of dereliction, it is about to enter the first truly useful phase of its 175-year life.

The building, which may even claim to be the world’s oldest mainline engine shed, has escaped from the spectre of demolition and has been converted into stylish social housing, with the first residents about to move in.

The shed is off Haughton Road, beside the East Coast Main Line and, fittingly, it has been converted by the Railway Housing Association.

Its story begins after the first stretch of mainline, from York to Darlington’s Bank Top, was completed in 1841 by the Great North of England Railway (GNE). Then the Newcastle & Darlington Junction Railway (N&DJR), headed by George “the Railway King” Hudson, began plotting the second stretch of mainline from Darlington to Gateshead.

It was complete on April 15, 1844, and now the railway passenger could travel 80 miles from York to Darlington to Tyneside.

However, the two companies operated the route, and they didn’t share engines. So inside Bank Top station, the engines were changed, so that GNE engines could operate the southern York section and N&DJR engines could run on the northern section to Gateshead.

The GNE had a shed near Bank Top’s primitive station in which to keep its engines, and so on August 16, 1844, the N&DJR instructed its architect, George Townsend Andrews, to build it a shed in which to keep its engines.

And so the Haughton Road shed was built within spitting distance of the handover point at Bank Top.

However, on July 1, 1845, the N&DJR took over the GNE and operated the whole of the mainline. Therefore, there was no need for an engine exchange at Bank Top, and so the Haughton Road shed was redundant within six months of its completion.

It was downgraded to odd jobs, like maintenance and storage. Within 40 years, as engines grew faster and bigger, it was too small, and so its odd jobs became odder.

Because it was small, it was largely forgotten about. Because it was mildly useful, it wasn’t so totally useless as to be demolished. And because it wasn’t used very much by the big steam engines, its wooden-framed roof didn’t catch fire, which was the fate suffered by many early shed.

So, somehow, it survived.

In 2004, British Rail finally decided it was surplus to requirements and sold it to a developer based in the British Virgin Islands. It applied for permission to demolish the shed once and for all and build 65 houses on its site.

Spirited readers of Memories, who belonged to organisations like Darlington Civic Trust and the Friends of North Road Railway Museum, went into battle on its behalf, and in 2008, it was granted Grade II listed status.

English Heritage said that “it is a rare surviving example of a first generation railway engine shed and it is highly significant for the evolution of early railway building design”.

It helped that it was designed by Andrews, a decent architect on whose buildings Hudson lavished money until the Railway King’s empire collapsed under the weight of its own extravagance. Andrews is perhaps best known for designed Richmond station.

Rescued from demolition, the shed and the derelict land around it was taken over by the Railway Housing Association. It had to clear out contamination – both Victorian railway-related and modern drug-connected – and convert the shed into seven mews-style houses. It is at the centre of an £8m social housing development of 73 properties of different shapes and sizes, which will be home to people on the waiting lists of Darlington council and the Association.

To add to the many complications of converting an old building, the shed is also on the trackbed of the Stockton & Darlington Railway (S&DR). With the help of the Friends of the S&DR, the Association has aligned its development so there has been no building on the 1825 trackbed.

And so, as the shed approaches its 175th birthday, it has finally found a purpose for its life. There is hope for us all yet.