Yui is the first Japanese astronaut with military background, and was forced to retire due to the historical policy by Japanese government which separates the scientific field from military works. After astronaut candidate training, he was certified as an ISS astronaut in July 2011. Yui served as an aquanaut aboard the Aquarius underwater laboratory during the undersea exploration mission in June 2012. The NEEMO 16 crew successfully "splashed down" at 11:05 am on June 11. On the morning of June 12, Yui and his crewmates officially became aquanauts, having spent over 24 hours underwater. The crew safely returned to the surface on June 22. In November 2016, Yui became Chief of the JAXA Astronaut Corps.
Expedition 44/45
In 2013 Yui was assigned as backup Flight Engineer for Italian astronaut Samantha Cristoforetti for ISS Expedition 42/43. Cristoforetti launched onboard Soyuz TMA-15M alongside fellow Expedition 42/43 crewmembers Anton Shkaplerov and Terry Virts 23 November 2014, following which Yui began training as prime crew Flight Engineer for ISS Expedition 44/45 alongside Roscosmos cosmonaut Oleg Kononenko and NASA astronautKjell Lindgren. Yui launched onboard Soyuz TMA-17M alongside Kononenko and Lindgren on 22 July 2015 from the Baikonur Cosmodrome in Kazakhstan, a solar panel on the Soyuz failed to deploy once the spacecraft got to orbit although this was not mission-critical, and the crew successfully docked with the ISS six hours later, officially becoming members of the Expedition 44 crew alongside Russian cosmonauts Gennady Padalka and Mikhail Kornienko as well as NASA astronaut Scott Kelly. During Expedition 44 Yui robotically supported the arrival of JAXAs HTV-5uncrewed resupply spacecraft in August 2015 and was part of a rare "direct handover" period on board the ISS where nine crew members were present on board the station following the arrival of Soyuz TMA-18M and before the departure of Soyuz TMA-16M, this handover was carried out in order to allow Kornenko and Kelly to remain on board the ISS for a full year. Yui remained on board the ISS alongside Lindgren, Kononenko, Korneninko and Kelly following the departure of Soyuz TMA-16M, after which the five transferred over to Expedition 45, they were joined by Russian cosmonaut Sergey Volkov who brought the crew up to six members. During Expedition 45 Yui supported two spacewalks, made by Lindgren and Kelly on 28 October and 6 November 2015, and supported the arrival of Orbital ATK's Cygnus CRS OA-4OA-4. On 11 December 2015 Yui, alongside Kononenko and Lindgren undocked from the ISS, officially ending Expedition 45 and starting Expedition 46, the trio landed on the Kazakh Steppe on the same day following 141 days in space.