The presidential oath of office is required by Article 2, Section 1 of the Constitution, which deals with the executive branch and outlines how the president is elected. In part, it reads:
Before he enter on the Execution of his Office, he shall take the following Oath or Affirmation:--"I do solemnly swear (or affirm) that I will faithfully execute the Office of President of the United States, and will to the best of my Ability, preserve, protect and defend the Constitution of the United States."
The first one ever to take the oath? George Washington on April 30, 1789, in New York, NY.