He was the command module pilot of Apollo 14 (January–February 1971), circling the Moon for 35 hours while Alan Shepard and Edgar Mitchell explored the lunar surface. During the flight to the Moon, Roosa overcame a problem with docking the command module and lunar module, and was successful on the sixth attempt. He was selected as an astronaut in 1966, and retired from NASA in 1976.