The Pennsylvania Railroad Company was chartered by the Pennsylvania legislature on April 13, 1846 to build a private railroad line from Harrisburg to Pittsburgh. Construction began in 1847 and the first section opened from Harrisburg west to Lewistown on September 1, 1849. Further extensions opened to McVeytown on December 24, Mount Union on April 1, 1850, Huntingdon on June 10, and Duncansville on September 16, 1850, taking it to a connection with the Allegheny Portage Railroad on the east side of the Allegheny Ridge. On the other side of the ridge, the main line opened from Conemaugh west to Lockport on August 25, 1851. On December 10, 1851, sections opened from Lockport west to Beatty and from Pittsburgh east to Brinton, with a temporary stagecoach transfer between via the Southern Turnpike and a short turnpike branch built to Beatty. Part of that gap was filled on July 15, 1852, from Brinton east to Radebaugh, and on November 29 the full line was completed, forming the first all-rail route between Philadelphia and Pittsburgh, though still using seven of the original ten planes of the Allegheny Portage Railroad. Plane Number 1 of the Portage Railroad was bypassed by the PRR on April 1, 1852. Other planes began to be bypassed by the New Portage Railroad, completed in 1856, but on February 15, 1854 the PRR's new line opened, leaving the old one on the east side of the ridge in Altoona and running west via the Horseshoe Curve and Gallitzin Tunnel, only using a short portion of the old Portage Railroad near South Fork and a longer adjacent section of New Portage Railroad. A reciprocal trackage rights agreement made March 18, 1854, allowed the PRR to use that section for free. On March 21, 1849, the PRR contracted with Eagle Line, primarily a steamboat company, for through service over the Philadelphia and Columbia Railroad. The PRR obtained trackage rights over the Harrisburg, Portsmouth, Mountjoy and Lancaster Railroad, opened in 1838, on April 21, providing a route from Harrisburg to the Philadelphia and Columbia at Dillerville, just west of Lancaster. On September 1, the first section of the PRR opened, with all arrangements in place for service from Philadelphia to Lewistown. In 1853, the PRR surveyed the Lancaster, Lebanon and Pine Grove Railroad from Philadelphia west via Phoenixville to Salunga on the Portsmouth, Mount Joy and Lancaster Railroad. This was done in order to show the state that the PRR was willing to build its own alignment around the Philadelphia and Columbia. On August 1, 1857, the PRR bought the whole Main Line of Public Works. The Philadelphia and Columbia Railroad was integrated into its system. Most of the New Portage Railroad, just completed the previous year at a cost of $2.14 million, was abandoned, while short sections became local branches. The canals were abandoned, and short sections were filled and covered by rails. On January 1, 1861, the PRR leased the HPMJ&L, giving it full control of its main line. In 1904, the New Portage Railroad east of the Gallitzin Tunnels was reopened as the New Portage Branch, a freight bypass line. Conrail closed this line in 1981.