The St Andrews Railway was an independent railway company, founded in 1851 to build a railway branch line from the university town of St Andrews, in Fife, Scotland, to the nearby main line railway. It opened in 1852. When the Tay Rail Bridge opened in 1878, residential travel to Dundee was encouraged.

The railway was engineered as a low-cost line by Thomas Bouch. The company suffered adversely from that in later years, and sold their line to the larger North British Railway in 1877.

The line was successful until road transport competition began to abstract traffic. When the Tay Road Bridge opened in 1966, 40% of the line's passenger carryings were lost immediately. Decline continued, and the line closed completely in 1969.

History

Before the St Andrews Railway

The town of St Andrews is ancient. The University of St Andrews was founded in 1413, but there was relatively little industry in the town, linen weaving being the chief occupation., and agriculture; there was a paper mill at Guardbridge.John Thomas and David Turnock, A Regional History of the Railways of Great Britain: Volume 15, North of Scotland, David and Charles, Newton Abbot, 1989,

The engineer Robert Stevenson was commissioned to survey a railway route crossing Fife in 1819; the route he selected was similar to the later Edinburgh, Perth and Dundee Railway, running some distance from St Andrews. However this would have been a long distance route and the steam locomotives of the day were not practicable, and the scheme was dropped.

In 1835 John Geddes surveyed a line from Burntisland to Ladybank, forking there and running respectively to Perth and the location that became Tayport. This scheme also failed to develop into a proposal, but a revised survey of 1840 gained support as the economic situation improved, and as railways elsewhere had demonstrated that longer distances could be handled by railways. In 1840 the Edinburgh and Northern Railway was proposed, following this route, and the proposal led to an authorising act of Parliament, the Edinburgh and Northern Railway Act 1845 (8 & 9 Vict. c. clviii) on 31 July 1845.

There were some late changes to the proposed route, but the Edinburgh and Northern Railway's line opened on 20 September 1847 between Burntisland and Cupar by way of Kirkcaldy and Ladybank. The company had changed its name on 27 July 1847 to the Edinburgh Perth and Dundee Railway (EP&DR) on merging with its partner railway at Granton.Christopher Awdry, Encyclopaedia of British Railway Companies, Patrick Stephens Limited, Wellingborough, 1990, It extended to Leuchars, not far from St Andrews on 17 May 1848. The Edinburgh and Northern was an immediate success, although the Forth had to be crossed by ferry from Granton: at this stage there was no question of bridging the Forth or the lower Tay.

The original prospectus for the Edinburgh and Northern had included a branch line to St Andrews, but this was not included in the parliamentary bill. By November 1846, shareholders were asking if the St Andrews branch should now be addressed. In the following parliamentary session, a bill was presented, and the Edinburgh and Northern Railway (St. Andrews and Newburgh Harbour Branches and Road Crossings, Newport Railway Extension) Act 1847 (10 & 11 Vict. c. cclxxvii) was passed on 22 July 1847.

At this stage, before the first train had run on the main line, the Edinburgh and Northern, soon to be the EP&DR, was concentrating its resources on construction of its extensive original routes. Completion to Ferryport-on-Craig (renamed Tayport) and giving ferry access to Dundee was only achieved on 17 May 1850, and by then the company had run out of money.Andrew Hajducki, Michael Jodeluk and Alan Simpson, The St Andrews Railway, Oakwood Press, Usk, 2008,

A local scheme

People in St Andrews, seeing the reality of the Edinburgh and Northern position, decided that independent action was called for, and on 19 December 1850 a meeting agreed to promote a local scheme. They moved quickly and obtained the authorisation for their railway by the (14 & 15 Vict. c. liv) of 3 July 1851,E F Carter, An Historical Geography of the Railways of the British Isles, Cassell, London, 1959 with capital of £21,000. It was emphasised that the subscribers to the line were local, avoiding getting involved in the contrary strategies of remote shareholders, and the directors of the new company had no previous railway experience.

They engaged as their engineer Thomas Bouch, and the contractor was Kenneth Matthieson. This was Bouch's first commission in private practice, and he determined to make a name for himself by designing cheap local railways. He argued that the later profitability of heavily engineered lines was dragged down by large and unnecessary costs at the construction stage.John Thomas, Forgotten Railways: Scotland, David and Charles, Newton Abbot, 1976, Once again the Company moved quickly, for the contract for construction was signed with Mathieson on 11 August 1851.

The new line was to make a physical junction with the Edinburgh and Northern line about a mile south of Leuchars station;There was no station at the point of junction until 1878; for the time being, St Andrews trains continued along the EP&DR line to Leuchars station. Thomas (page 12) refers to the 1878 Junction station out of chronological order, implying immediate provision, but that was not the case. the village of Leuchars was small at the time. There was to be one intermediate station at Guardbridge,Frequently spelt Guard Bridge. immediately west of the River Eden crossing. St Andrews was a considerable community at the time, and the station there was some distance short of the centre, at the "sheep park",James K Corstorphine, East of Thornton Junction: The Story of the Fife Coast Line, self published by Corstorphine, Leven, 1995, just beyond the seventeenth hole of the Old Course. The Royal and Ancient Golf Club had vigorously opposed a closer approach.

Completion and opening Construction proceeded well and opening was anticipated for the end of June 1852. The line travelled over flat land which had been cheaply acquired.William Scott Bruce, The railways of Fife, Melven Press, 1980, , pages 80 - 84 An arrangement with the Edinburgh and Northern Railway whereby they would work the trains was concluded, to run for 25 years from 1 July 1852, with the E&NR paying 4.5% on St Andrews Railway shares. Captain Laffan of the Board of Trade inspected the line on 24 June 1852 and approved it for opening.

There was an official opening ceremony on 29 June 1852 and a full public opening on 1 July 1852.Hajducki and Thomas (NBR volume 1); Ross (page 38) says opening was on 29 May 1852.David Ross, The North British Railway: A History, Stenlake Publishing Limited, Catrine, 2014, John Thomas, The North British Railway, volume 1, David & Charles, Newton Abbot, 1969, The line had cost £21,565 to construct.This was reckoned when there were still some payments due for land and final works; the gross cost of construction was probably £25,314. The train services consisted of four trains each way daily except Sundays.

Passenger traffic developed well, and there was a considerable volume of excursion traffic in to St Andrews. Coach services were run from some of the nearby towns, including Crail, Pittenweem and Anstruther, to St Andrews, enabling onward travel by train. The journey on the branch took twenty minutes. July saw a "monster" excursion to Glasgow.

Goods traffic was less significant, reflecting the relative absence of industry at St Andrews.

Although some improvements had been made to the Leuchars station (which had been built as a rudimentary wayside stop) there were complaints about the connectional arrangements there. The branch trains made poor connections with the main line trains, and delays were attributed to improper formation of the main line trains.

Poor quality of track and bridges

As early as 1853 the company was experiencing difficulty with the permanent way; Bouch's scheme for cheap railway construction had included laying sleepers at a pitch of four feet, considerably wider spacing than was usual. There were two significant timber trestle bridges over tidal water, at the Water of Mottray and the River Eden. At this time they were considered to be deteriorating, and it was observed that they had not been treated with preservative at the time of construction: another of Bouch's cost-saving measures.

On 29 July 1862 the EP&DR was taken over by the North British Railway (NBR). The larger company reviewed the arrangements at St Andrews. Locomotive technology had developed over these early years, and heavier and more efficient locomotives were in common use.Thomas says that the engine concerned was to be a small Hawthorn four-coupled tank. The NBR wished to bring them on to the line, but the track and the bridges were considered not strong enough to accommodate them. It was said that £16,000 to £20,000 was required to replace the wooden bridges. This was utterly beyond the financial resources of the St Andrews Railway Company, which now began to think of selling their line to the NBR. Bouch was asked directly by the NBR chairman to consider the matter and he estimated that £12,561 was enough to relay the track in stronger materials and to replace the two bridges.

When the St Andrews Railway Board discovered that this discussion had been taking place behind their backs, they were outraged: "No company would employ engines of 30 tons or upwards to work a branch 4½ miles in length." Hodgson, the chairman of the North British Railway had been preparing plans to absorb the St Andrews Railway, but the board of the latter made it clear that they would oppose any parliamentary bill for such an acquisition, and the NBR was obliged to let the matter drop. Notwithstanding the bad feeling between the two Companies, the contractual working agreements was still in force, and from June 1863 there were seven passenger trains each way daily, an eighth on Saturdays.

On 16 May 1864 there was a derailment at Guardbridge. An afternoon train from Leuchars to St Andrews hauled by an 0-4-2 locomotive running tender first and hauling four passenger vehicles, derailed at a rail joint that had become displaced. The tender and locomotive left the track, but there were no injuries. Captain Rich of the Board of Trade reported on the accident, and he was extremely critical of the state of maintenance of the track; he concluded: "The accident ... was caused by the bad state of the St Andrews Railway." He said that, "The line is of very light and poor construction," and that the chairs "are weak, too narrow in the throat to admit a good key, and reported to be continually breaking". He added "I consider that the whole permanent way wants renewing." He was also critical of the strength of the river bridges, and of the signals on the line.Report of Captain Rich to the Railway Department of the Board of Trade, dated 2 July 1864

The Board of the St Andrews company evidently did not agree, for they protested that the wooden bridges were never intended to be permanent, and at the next Shareholders' Meeting declared the customary dividend of 4.5% instead of allocating any income to capital works improvements.

Sale to the North British Railway