Due to a series of lucky events for Rayburn, the House district of his home county of Fannin County, the fourth district, was open for him to run. Senator Joseph Weldon Bailey was rocked by allegations of corruption and bribery involving oil companies so he announced his resignation effective January 1913. The longtime incumbent representative of the fourth district, Choice B. Randell, ran for Bailey's open senate seat in the 1913 election and lost. Rayburn won election to the House of Representatives in 1912 after a bruising Democratic primary where he won by only 490 votes. He won the general election afterwards and became a Representative. He entered Congress in 1913 at the beginning of Woodrow Wilson's presidency and served in office for almost 49 years (more than 24 terms), until the beginning of John F. Kennedy's presidency.
Rayburn was a protege of then-Representative John Nance Garner. Despite Rayburn's freshman status, in 1913, Garner helped him become a member of the powerful House Interstate and Foreign Commerce Committee, which handled legislation pertaining to commerce, bridges, coal, oil, communication, motion pictures, securities exchanges, holding companies and the Coast Guard. Rayburn learned how to make deals and how to deal with adversity during his first two decades in the House. While he was a young representative he introduced and helped pass numerous anti-trust and railroad-related legislation such as the Clayton Antitrust Act of 1914, the Federal Trade Commission Act of 1914 and the Esch–Cummins Transportation Act (The Railway Stock and Bond Bill that was originally introduced in 1914 was the first ever major legislation that was crafted and proposed by Rayburn. In 1920 it finally became law in the Esch-Cummins Act).