The Long Island Rail Road is a railroad owned by the Metropolitan Transportation Authority in the U.S. state of New York. It is the oldest United States railroad still operating under its original name and charter. It consolidated several other companies in the late 19th century. The Pennsylvania Railroad owned the Long Island Rail Road for the majority of the 20th century and sold it to the State in 1966.

Gateway to Boston, 1832–1840s The LIRR's history stretches back to the Brooklyn and Jamaica Rail Road, incorporated on April 25, 1832 to build a ten-mile line from the East River in Brooklyn through the communities of Brooklyn, Bedford, and East New York to Jamaica. B&J engineer Major D. B. Douglass soon began planning for a continuation, forming part of an 11-hour combination rail and steamship route between New York City and Boston in cooperation with the New York, Providence and Boston Railroad and Boston and Providence Rail Road. The current all-land route (Shore Line) across southern Connecticut was considered impassable at the time due to numerous hills and river valleys. Douglass attracted wealthy New Yorkers and Bostonians, who received a charter for the Long-Island Rail-Road Company on April 24, 1834, with the right "to construct, and during its existence to maintain and continue a rail-road or rail-roads, with a single or double track, and with such appendages as may be deemed necessary for the convenient use of the same, commencing at any eligible point adjoining Southold Bay, in or near the village of Greenport, in the county of Suffolk, and extending from thence, on the most practicable route, through or near the middle of Long-Island, to a point on the water's edge in the village of Brooklyn, in the county of Kings, to be designated by the trustees of that village, and to a point on the water's edge in the village of Williamsburgh, in the said county of Kings, to be designated by the trustees of that village, and in like manner to construct, maintain and continue a branch rail-road from the said main road to Sag Harbor". It was also authorized to unite with the Brooklyn and Jamaica with the consent of that company.An Act to Incorporate the Long-Island Rail-Road Company, Passed April 24, 1834, reproduced at

Since its plan was not to serve local traffic on Long Island, the LIRR chose not to serve existing communities along the shores of the island, but built straight down the middle of the island, which was largely uninhabited at the time and relatively free of grade crossings. This straight route was the quickest and the easiest to build, compared to the options of building along the northern coast of Long Island, or in a north-central route following the Middle Country Road. The LIRR was organized on June 17, 1835, and Knowles Taylor was elected president.

After one or more trial runs in February 1836, the Brooklyn and Jamaica opened its full line, roughly along the present Atlantic Avenue from South Ferry to 151st Street in Jamaica, on April 18, 1836. The B&J never operated its own trains, since that same day it was leased to the LIRR for $33,300 a year, a rather high amount for the time based on expected heavy traffic to Boston. Even before the B&J opened, the LIRR began planning a branch to the Grand Street Ferry in Williamsburg, leaving the B&J at Bedford, to avoid congestion in Brooklyn. The LIRR started to build the B&J's continuation beyond Jamaica immediately upon completion of the Brooklyn-Jamaica line,, June 2004 Edition opening to Hicksville on March 1, 1837.

Hicksville remained the terminal for the next four years due to the financial panic of 1837. The entire line was a single track, but the roadbed was graded for two tracks with a width of 28 feet. According to a February 24, 1837 announcement, a station called Westbury Hempstead was added. By June, the station was renamed Carle Place. At this location, passengers for Westbury and Hempstead would transfer to stagecoaches. As early as March 1837 a stop at the Union Course Race Track is listed, and as late as June 1837 the station is listed on timetables as Wyckoff's Lane. The September 8, 1837 timetable shows Pennsylvania Avenue and Connecticut Avenue (later Woodhaven Boulevard) as stations instead of Union Course. Because steam trains were not allowed in the City of Brooklyn, from 1836 to 1839, trains were pulled by horses between Brooklyn and Bedford. Also along the way to Hicksville, a station was added at Willow Tree.

On May 16, 1836, a supplement to the charter authorized a branch to Hempstead, and surveying was done for the branch in 1838. The short Hempstead Branch, running south from the Main Line at Mineola, opened in July 1839 from Hempstead Branch station (later Mineola) down Main Street, terminating between Fulton Street and Centre Street., June 2004 Edition The branch was served using a small dummy train, shuttling passengers on the branch. The LIRR slowly extended east, reaching Farmingdale on October 18, 1841, and reaching Deer Park in 1842, which was the stopping place for the shore villages of Huntington and Babylon, even though they were miles away.

Later in 1842, the line reached Suffolk station, and in 1844, it reached Medford and Millville. After this point, the building of the line was split into two sections, one from Greenport and one from Millville, both meeting up at St. George's Manor. These were the most difficult sections to complete, but the Main Line was completed, and service began on July 27, 1844. An opening excursion to Greenport was operated on July 27, 1844, making the trip in three and a half hours, and revenue service began over the full line on July 29. Because the route bypassed the communities on the north and south shores, people from these areas had to drive six or more miles in a stagecoach to get to the line.

The LIRR bought the steamboat Cleopatra from Cornelius Vanderbilt, then known for his ferry empire, to cover the Long Island Sound crossing, and began operating to Stonington, Connecticut on August 10. Vanderbilt was elected to the LIRR board of directors on November 26. The opening of the Cobble Hill Tunnel along the Brooklyn and Jamaica west of downtown Brooklyn on December 3, 1844, decreased the grade to the waterfront and allowed locomotives to run through to South Ferry, eliminating a horse car transfer., May 2004 Edition

The LIRR began operating the Worcester and New Haven steamboats in 1845, and established a second route to Boston via steamboat to Allyn's Point and the Norwich and Worcester Railroad and Boston and Worcester Railroad. But competition from the Hartford and New Haven Railroad (completed 1844) and steamboats from New York caused the LIRR to sell the Worcester and Cleopatra to the N&W in July 1846, and the early 1847 completion of the Fall River Line cut into profits enough that the New Haven was sold to Jacob Vanderbilt, ending Boston express service.

Local focus, 1840s–1875 The final blow came in December 1848, when the New York and New Haven Railroad opened through the "impassable" country of southern Connecticut, forming part of an overland route via New Haven and Springfield. With only one short branch, the LIRR was not built to serve local Long Island traffic,, April 2005 Edition and it was decades before it had fully adjusted to its new role. In part due to the high cost of the Brooklyn and Jamaica lease, the LIRR entered receivership on March 4, 1850,, March 2005 Edition but ended it without foreclosure on January 25, 1851., March 2005 Edition, May 2004 Edition Most of the population of Long Island was closer to the shores than the LIRR's central alignment; only limited success was had in inducing settlers on the central Long Island scrub oak and pine barrens. An amendment to the LIRR's charter passed April 21, 1862 allowed it to build branches anywhere east of Jamaica. Several branches on the north and south shores were built under this clause.

Branches to the north and south shores In 1851, under the General Railroad Act, the Hicksville and Cold Spring Branch Railroad was organized to build a line running northeast from Hicksville to Cold Spring. Oliver Charlick was motivated to build the line because of his fear of competition. The railroad was chartered on November 7, 1853, and it was completed to Syosset by July 3, 1854, and the right-of-way to Cold Spring Harbor was graded to White Oak Tree. This line was leased by the LIRR and was successful, tapping the rich farmland of the central North Shore. Syosset got almost all of its ridership from the villages of Oyster Bay, Huntington and Northport.

However, it was not yet complete. The line was intended to go to through White Oak Tree, present-day Laurel Hill before going to Cold Spring Harbor. There was insufficient funding for the project, and the LIRR got an extension from the Legislature in February 1858. Because of the Civil War the extension was impractical. The Hicksville and Cold Spring Branch Railroad had legislative approval to run as far as Cold Spring Harbor, but Charlick wanted an extension to Huntington. As a result, permission for the three miles of right-of-way had to be obtained. The iron to extend the railroad had been purchased in February 1866. The right-of-way began to be graded in May 1867. The right-of way and track that was once intended to terminate at Cold Spring Harbor was abandoned and a new right-of-way running east was built.

The line was extended to Huntington on January 13, 1868, and to Northport on April 25, 1868., March 2005 Edition The Smithtown and Port Jefferson Railroad was organized on June 3, 1870, to build from Northport Junction to Port Jefferson, opening on January 13, 1873. Northport then became the end of a mile and a half long branch., February 2005 Edition Passenger service to Northport ended in 1899.

When the LIRR was charted in 1834, it was authorized to construct a branch line to Sag Harbor, and in 1854, a survey was made for a branch from Riverhead to the Hamptons and Sag Harbor. However, the line was not built. The South Side Railroad of Long Island ran as far as Patchogue on the South Shore, and in order to insure a monopoly on the East End, President Oliver Charlick proposed building a branch to Sag Harbor, as it was originally planned, branching from Riverhead. However, Riverhead residents were not interested in a branch line, and Manorville was chosen as the split location. The line was to turn eastward to Sag Harbor at Eastport. The Sag Harbor Branch (now mostly part of the Montauk Branch), was finally opened from Manorville on the main line to Hampton Bays in 1869 and to Bridgehampton and Sag Harbor on May 9, 1870.

The Glen Cove Branch Railroad was incorporated on December 3, 1858. The Locust Valley Branch, now the Oyster Bay Branch, opened from Mineola on the main line north to Glen Head on January 23, 1865, and to Glen Cove in 1867, before finally being extended to Locust Valley on April 19, 1869., June 2004 Edition

However, the building of branches was retarded by the LIRR presidency of Oliver Charlick between 1863 and 1875. Charlick was known for only building branches where necessary to cut off plans by locals to build competing lines.

Charlick also rebuilt the wharf at Greenport in 1870, and operated a new Boston route via New London, the New London Northern Railroad, and the newly opened Boston, Hartford and Erie Railroad from September 1872 to 1875.

Brooklyn