Kennedy ran in the 1960 presidential election. His campaign gained momentum after the first televised presidential debates in American history, and he was elected president, narrowly defeating Republican opponent Richard Nixon, who was the incumbent vice president. He was the first Catholic elected president.
Kennedy's administration included high tensions with communist states in the Cold War. He increased the number of American military advisers in South Vietnam. He authorized numerous operations to overthrow the Cuban government of Fidel Castro, including the failed Bay of Pigs Invasion in April 1961. The following October,  U.S. spy planes discovered Soviet missile bases in Cuba; the resulting period of tensions, termed the Cuban Missile Crisis, nearly resulted in the breakout of a global thermonuclear conflict. He also signed the first nuclear weapons treaty in October 1963. Kennedy presided over the establishment of the Peace Corps, Alliance for Progress with Latin America, and the continuation of the Apollo program with the goal of landing a man on the Moon. He also supported the civil rights movement but was only somewhat successful in passing his New Frontier domestic policies.
On November 22, 1963, Kennedy was assassinated in Dallas. 