Charles Bolden and Lori Garver have both worked at Nasa before
The US Senate has confirmed Charles Bolden as the new administrator of the American space agency (Nasa).
Mr Bolden is a former astronaut who flew on four space missions, including the shuttle flight in 1990 that launched the Hubble Space Telescope.
He becomes the 12th Nasa administrator since the agency was created in 1958.
The Senate also voted through the appointment of his deputy, Lori Garver, who acted as a space adviser to Barack Obama during his presidential campaign.
Major General Bolden's confirmation came just hours after the Endeavour orbiter successfully blasted off towards the International Space Station (ISS) on a mission to finish work on a Japanese research laboratory.
Charles Bolden described his selection as administrator of the National Aeronautics and Space Administration as an "honour".
"Today, we have to choose. Either we can invest in building on our hard-earned world technological leadership or we can abandon this commitment, ceding it to other nations who are working diligently to push the frontiers of space," he said in a statement after his confirmation.
He called on the US to build on its investment in the International Space Station, and to accelerate development of its next-generation launch systems.
Maj Gen Bolden also underlined the need to enhance Earth observation programmes and to inspire young people to take up careers in science and technology.
A native of Columbia, South Carolina, he becomes only the second astronaut to run Nasa. Vice Adm Richard Truly was the first.
He succeeds Dr Mike Griffin who initiated the Constellation programme, a new space transportation system to replace the shuttle which is due to come out of service next year.
In May, President Obama ordered a review of Constellation and Nasa's human spaceflight plans. Norman Augustine, a former aerospace industry executive, is expected to deliver a report to the White House in August.
As with Maj Gen Bolden, Lori Garver's confirmation also marks the second time she has worked for Nasa. She was an official in policy and planning from 1996 to 2001.