One of the most interesting locations that railroads have been built to is Cape Cod. The road that operated to CapeCod was part of the New York, New Haven & Hartford.
The railroad era came to Cape Cod in 1848 when a road was built from Middleboro on the mainland to Sandwich on the Cape. It was built primarily to serve the Boston and Sandwich Glass Company. The Cape Cod Railroad extended itself to Hyannis in 1854 and after the Civil War the Cape Cod Central Railroad went on to Orleans and Wellfleet.
Passenger service became important by the end of the 19th Century as the Cape became a resort area.
The late 1950’s saw a sharp decline in passenger travel as automobiles became more popular (the Bourne and Sagamore bridges to Cape Cod were no where as overloaded as they are today).
Tracks from Eastham to Provincetown were removed in 1960 and then cut back to South Dennis in 1966. Much of this line is a bike path.
No, you couldn’t take a train to Cape Cod for quite a while, but see 2013 story: Cape Cod is Finally Going to Town
Find out more about railroads on Cape Cod