The United States Oath of Allegiance, officially referred to as the "Oath of Allegiance," is an allegiance oath that must be taken by all immigrants who wish to become United States citizens. The Oath of Allegiance may be administered by USCIS officials; by immigration judges; and by eligible courts.

The Oath of Allegiance for prospective citizens originated with the Naturalization Act of 1790, which required applicants to take an oath or affirmation "to support the constitution of the United States", but did not provide a text. The Naturalization Act of 1795 added renunciation of the new citizen's former sovereign to the oath. The Naturalization Act of 1906 added the section of the oath requiring new citizens to defend the Constitution and laws of the United States of America against all enemies, foreign and domestic; and bear true faith and allegiance to the same.

The Oath acquired a standard text in 1929. Prior to then, spoken oaths were adapted from naturalization law, and each court could develop its own procedures for administering the oath.

The Internal Security Act of 1950 added the text about bearing arms and performing noncombatant service in the armed forces of the United States. The section about performing work of national importance under civilian direction was added by the Immigration and Nationality Act of 1952.

More Info: en.wikipedia.org