Introduction:
An interesting article from CBS News (which has a nice graphic showing the longest time spent in space). The first man to spend time in space was Russian Yuri Gagarin. He stayed in orbit for three hours and fifty minutes.
There have been many people who have spent time in space. Some stayed in orbit for a relatively short period of time such as Yuri Gagarin and Frank Borman who spent just 2 days in space.
Who spent the longest time in space?
For a long time, it was not clear who had spent the longest time in space. The record for the longest single spaceflight was held by Valery Polyakov who spent 437 days on board Mir before finally returning to Earth in March 1994. He holds the record of being the only human to have spent more than 342 days in space (but not at once).
However, his record was broken by Gennady Padalka in 2008 when he spent 937 days in orbit aboard the International Space Station. This has since been broken by Roman Romanenko, who spent 879 days on board Mir before returning to Earth on December 18th, 2011.
The record for the longest time spent in space belongs to cosmonaut Gherman Titov, who spent 196 days aboard the Soviet Union's Vostok 3KA spacecraft. He returned to Earth on June 17, 1962.
The record for the shortest time spent in space belongs to astronaut Gordon Fullerton, who spent just over three minutes aboard NASA's Gemini 4 spacecraft in March 1965.
The record for the longest time in space belongs to Valeri Polyakov, a Russian cosmonaut who spent 438 days aboard the Mir space station from 1990-91. He beat out American astronaut David Scott by about 30 days.
Polyakov's mission was not only longer than Scott's but also more difficult. Unlike Scott, who lived in a pressurized cabin and could go outside from time to time to see the Earth below him, Polyakov spent much of his time in orbit trapped inside a cramped Soyuz capsule with little opportunity for exercise or fresh air.
The record holder for the longest time spent in space is Yuri Gagarin, who orbited Earth just once on April 12, 1961. The current record-holder is Sunita Williams, who spent 534 days on the International Space Station.
Conclusion:
The longest time in space was spent by Valeri Polyakov, who spent 437 days and 18 hours on the Russian space station MIR. Next came Anatoly Solovyev and Björn Nyberg, who each spent more than 4 months in space. Third was Sergei Avdeyev, who spent a little over 115 days in space. The shortest amount of time in space was totaled by astronaut Leroy Chiao, who spent 5 months, 24 days, and 7 hours in Space.
This list should give you a little bit more of an insight into just how much time space-farers from different countries spent in space over the course of their careers. The takeaway? The Russians have spent a lot of time in orbit, especially if you count the career time of Mir astronauts prior to the Shuttle-Mir program. Enjoy!