Astronauts may be exceptionally brave, intelligent, and accomplished, but they're not superhuman: they still have to poop and pee when they leave Earth.

But as NASA was working to get the first humans into space in the early 60s, the agency didn't focus much on how astronauts would empty their bladders and evacuate their bowels once they were up there.

Then in 1961, astronaut Alan Shepard – the first American in space – was forced to pee his pants on the launchpad. NASA quickly realised that the lack of planning presented a rather messy problem.

The agency needed a more serious bathroom-break plan, but solutions weren't easy. After the Apollo missions ended in 1975, engineers described defecation and urination as the "bothersome aspects of space travel".

A variety of makeshift solutions have been sent into space, including pee bags, roll on "cuffs", diapers, strappy toilet seats, and US$19 million commodes. Contraptions for "going" while weightless have gotten a little more comfortable, and astronauts are now generally good at keeping waste from floating around.

But retired astronaut Peggy Whitson, who logged a record-breaking 665 days in space for NASA, recently said that going to the bathroom in space was her least favourite part of working in zero gravity.

Here's the full story of how astronauts have relieved themselves in space, from 1961 to now:

On May 5, 1961, when Alan Shepard piloted the first human space flight for the US, there was no pee plan.

The flight was only supposed to last for around 15 minutes. But the engineers didn't consider how long Shepard might have to sit on the launchpad first.

Astronaut Alan Shepard after his Mercury capsule was recovered (NASA)Astronaut Alan Shepard after his Mercury capsule was recovered (NASA)

Shepard sat inside the nosecone for some time, then realised his bladder was getting uncomfortably full. The crew insisted he stay put, so Shepard let them know he was going to go in his seat.

"Of course with a cotton undergarment, which we had on, it soaked up immediately," he later said. "I was totally dry by the time we launched."

After that, NASA started giving astronauts some urination equipment.

Some of the first pee-catchers looked like urine condoms and came in three sizes. NASA called them roll-on cuffs, and they were not designed to be used by women.

Roll-on cuff (Smithsonian)Roll-on cuff (Smithsonian)

The latex cuff was connected to a plastic tube, valve, clamp, and a collection bag. It wasn't a great system, and sometimes leaked.

The cuffs were what John Glenn used on his Mercury Atlas 6 mission — the first time a human went into orbit for NASA. The flight lasted 4 hours and 55 minutes.

The Gemini missions of the 1960s were the first time NASA attempted to deal with poop in space. The first devices were just bags taped to astronauts' butts.

"After defecation, the crewmember was required to seal the bag and knead it in order to mix a liquid bactericide with the contents to provide the desired degree of faeces stabilisation," NASA said.

"Because this task was distasteful and required an inordinate amount of time, low residue foods and laxatives were generally used prior to launch."

This contraption used in the Apollo missions wasn't much better. It was still a baggie system.

(NASA)(NASA)

NASA even has a log of all the poos collected on the Apollo missions.

But not every specimen got collected as planned. During the Apollo 10 mission in 1969, astronaut Tom Stafford suddenly said: "Get me a napkin quick. There's a turd floating through the air."

Was it astronaut John Young's?

"I didn't do it. It ain't one of mine," Young said, as recorded in a NASA transcript.

NASA also developed a "faecal containment system" for Apollo astronauts, since it was impossible to use bags outside the spacecraft. The system consisted of "a pair of undershorts with layers of absorbent material".

The shorts "would serve to contain any excreta," according to NASA.

Finally, the space shuttle era arrived and with it, women (and toilets!) in space.

To enable women astronauts to pee during launch and on spacewalks, NASA created the Disposable Absorption Containment Trunk, which was kind of like bike shorts designed to absorb pee.

This garment can hold 3.75 cups of urine. (Smithsonian)This garment can hold 3.75 cups of urine. (Smithsonian)

The space shuttle came equipped with this US$50,000 toilet called the Waste Collection System.

It wasn't that easy to use – the opening was less than 4 inches (10 centimetres) wide, about a quarter of the size of a regular toilet hole.

Astronauts had to be toilet trained on Earth first, and some test runs even included a special under-the-seat camera so they could perfect their aim.

A space shuttle toilet simulator. (Dave Mosher)A space shuttle toilet simulator. (Dave Mosher)

"Alignment is important," NASA's Scott Weinstein, who taught space crews how to use the shuttle toilet, said in a video.

No paper was allowed in the toilet; that had to get thrown out separately.

Astronaut Mike Massimino said he used thigh restraints when he needed to sit on the space toilet, since sitting on it felt like riding a chopper bike. "I think of Peter Fonda in Easy Rider," he said. "That's the right position for me."

Today, astronauts at the International Space Station go to the bathroom into a little plate-sized toilet hole, and a fan vacuum-sucks their excrement away.

A separate funnel equipped with a fan suctions their pee away.

After the astronauts are done, their poop gets stored in a plastic bag, and eventually sent away on a cargo ship that burns up as it hurtles towards the Earth.

Italian European Space Agency astronaut Samantha Cristoforetti (ESA/Youtube)Astronaut Samantha Cristoforetti demostrating ISS toilet (ESA/Youtube)

Retired station commander Peggy Whitson, who's spent more time in space than any other NASA astronaut, told Business Insider that floating is great, but going to the bathroom in space is not.

"After it starts getting full," she said of the toilet, "you have to put a rubber glove on and pack it down."

The toilets on the ISS are pretty efficient at collecting urine: about 80-85 percent gets recycled and becomes astronaut drinking water.

But Whitson wants NASA to do better:

"We want a closed loop system, which means we have to recycle all our water," she said.

Today, male and female astronauts use these Maximum Absorbency Garments when doing spacewalks.

Maximum Absorption Garment (NASA)Maximum Absorption Garment (NASA)

The brand name for the gear was Absorbancies, but the company that made them for NASA doesn't exist anymore. NASA has its own stockpile.

The ISS toilet doesn't have a perfect track record: part of it went out of order in May 2008.

Luckily, the solid-waste function still worked, and a Soyuz spacecraft that was attached to the station at the time also had a toilet (but with limited capacity). For urine, astronauts had to use bags.

As the Associated Press reported, the toilet breakdown was a problem, since it was the only one on the station at the time.

Six months later, this US$19 million Russian-made toilet arrived at the ISS and became the station's second commode.

(NASA)(NASA)

This waste and hygiene compartment was delivered to the International Space Station aboard space shuttle Endeavour on the STS-126 mission. The Russian-built toilet system separately channels liquid and solid waste.

Last year, NASA launched a Space Poop Challenge to solve potential problems that could arise if astronauts are strapped into spacesuits for days at a time, like on missions to Mars. This device took top prize: US$15,000.

(Dr Thatcher Cardon)(Dr Thatcher Cardon)

The system is based around a little access port on the crotch, to which various bags or tubes can be attached to collect waste. It could even help astronauts change their underwear without taking off a spacesuit.

Thatcher Cardon worked nights and weekends on the prototypes with his wife and two teenage kids.

"I did all of the designing in my head. I'd lay down and think and visualise different concepts," Cardon previously told Business Insider.

"I thought, 'The waste needs to come out of the suit.'"

NASA isn't quite ready to use the system in its spacesuits, but said it might use "some aspects" to develop better ways for astronauts to go in their suits in the future.

(Dr Thatcher Cardon)(Thatcher Cardon)

Cardon, who's also an Air Force officer, a family physician, and a flight surgeon, says the same design concept could be used on other areas of the body for emergency surgeries.

"Put a port like that right over the navel, you could do abdominal surgery," he said. "If astronauts are ever in a situation in space where trauma is involved, like asteroid mining, you might want to have those ports there."

But it doesn't seem like space restrooms are going glam any time soon.

This article was originally published by Business Insider.

More from Business Insider: