The Sag Harbor Branch was a branch of the Long Island Rail Road that was the eastern terminal on the south shore line of Long Island from 1869 to 1895 and then was a spur from Bridgehampton to Sag Harbor, New York from 1895 to 1940.
The line was conceived and surveyed in 1854. In 1869 LIRR president Oliver Charlick wanted the branch to head off plans by the South Side Railroad to extend their line beyond Patchogue. The original plans called for the branch to leave the Main Line at Riverhead. But Riverhead refused to pay the LIRR for the benefits of being at a junction, so the west end was moved to Manorville in the pine barrens in 1869. During construction the Quogue station "on a Sunday morning" was moved by the village from its original and current location to a location on Old Depot Road.
The Sag Harbor Line remained the farthest point on the LIRR's south shore line until 1895 when the LIRR extended the road at Bridgehampton to Montauk leaving the Sag Harbor section a spur of the Montauk Line. During World War I, a freight spur was built onto the newly reinforced Long Wharf in Sag Harbor to deliver torpedoes for the E.W. Bliss Company for testing in the harbor.
The Sag Harbor branch was abandoned in 1940. A former section of the line in Sag Harbor known as Wharf Street has been designated Suffolk County Road 81 and runs from NY 114 to the Sag Harbor Pier. The rest of the road bed was transformed into the Long Pond Greenbelt. The road bed is now a hiking trail. The freight house at the Sag Harbor train station is now the Sag Harbor Garden Center.
The Manorville Branch was a segment of the Sag Harbor Branch, running from Manorville on the Main Line southeast to Eastport on the Montauk Branch, which eventually became its own branch. A small portion of the right of way runs through what is today the Long Island Game Farm, while another segment runs through a Town of Brookhaven compost facility. In Eastport, the line ran beneath a bridge under Suffolk CR 51, which no longer exists, then along the north end of Spadaro Airport, before merging with the Montauk Branch. It even contained a wye for westbound Montauk Branch trains that went over Montauk Highway until 1931.
The Manorville Branch was abandoned in 1949. In the 1950s, Suffolk County Department of Public Works planned to transform the former branch into a four-lane highway called Suffolk County Road 91 (Manorville Branch Road), but this proposal was abandoned on June 24, 1986,  and as with the Long Pond Greenbelt, this road bed is also now a hiking trail.
Besides the existing and former stations along the current Montauk Branch, stations along the line included the following;
to Penn Station
|For continuing service to points west, see Main Line (Long Island Rail Road)|
Raynor Road, Manorville
|Branch abanodned 1949, station closed in 1968.|
|Manorville Branch ends, merges with Montauk Branch|
North Phillips Avenue at Depot Road, Speonk
Station Road and Depot Road, Westhampton
|||Bus (Suffolk County Transit): S90|
|Quogue||Opened June 1875, Closed March 16, 1998|
|East Quogue||Opened 1871, Closed unknown|
|Hampton Bays 
Good Ground Road, between Springville Road and Ponoquogue Avenue, Hamton Bays
|||Bus (Suffolk County Transit): S90, S10D, S10E|
|Canoe Place||Opened 1935, Closed 1953|
|Suffolk Downs||Opened 1907, Closed 1921|
|Golf Grounds||Opened 1907, Closed 1939|
North Main Street, between Prospect Street and Willow Street, Southampton
|||Bus (Suffolk County Transit): S92, 10A|
|Water Mill||Opened 1875, Closed circa 1968|
Maple Lane and Butter Lane, Bridgehampton
|||Bus (Suffolk County Transit): S92, 10B|
|Montauk Branch continues east to Montauk, Sag Harbor Branch which was abaondoned in 1940|
|Noyack Road||||1906-1940; also known as Lamb's Corner Station|