Boeing received $92.3 million and privately held Sierra Nevada Corp got $80 million, NASA said.
Space Exploration Technology, the privately held company founded by Internet entrepreneur Elon Musk, was awarded $75 million. The company, also known as SpaceX, is considering an initial public offering next year, Musk recently said.
Blue Origin, founded by Amazon's Jeff Bezos, received a contract worth $22 million.
The companies were competing for the next round of funding in NASA's Commercial Crew Development program.
The program is aimed at developing a U.S. commercial alternative to fly astronauts to and from the International Space Station after the U.S. space shuttles are retired later this year.
The United States has already turned over flights to Russia at a cost of $51 million per person. The price is expected to increase to $63 million in 2014.
"We're committed to safely transporting U.S. astronauts on American-made spacecraft and ending the outsourcing of this work to foreign governments," NASA Administrator Charles Bolden said in a statement.
"These agreements are significant milestones in NASA's plans to take advantage of American ingenuity to get to low-Earth orbit so we can concentrate our resources on deep space exploration."
The companies chosen for the program came from a pool of 22, Philip McAlister, acting director of Commercial Spaceflight Development at NASA, told reporters during a conference call.
"At this stage of the game, competition is a very important part of our strategy," McAlister said. "We also believe that having skin in the game is important."
In addition to government funds, the companies will be expected to invest their own resources, a shift from how the United States has developed spacecraft in the past.
The agreement covers work for about 14 months. NASA hopes to follow the program with another competition to develop an actual flight system. The goal is for NASA to be able to buy commercial orbital space transportation services by about 2015.
Those losing out on NASA funding included Orbital Sciences Corp, Alliant Techsystems and United Space Alliance. Orbital Sciences has contracts to fly cargo for NASA. Alliant Techsystems proposed a new rocket based on the space shuttle booster, and United Space Alliance had sought funds to study if the shuttles could be flown commercially instead of being retired.
(Reporting by Irene Klotz; editing by Jane Sutton and Kevin Gray)