The Hubble Space Telescope should be back in action soon after a tricky, remote repair job by Nasa.
The orbiting observatory went dark in mid-June, with all astronomical viewing halted.
Nasa initially suspected a 1980s-era computer as the source of the problem, but after the back-up payload computer also failed, flight controllers at Maryland’s Goddard Space Flight Centre focused on the science instruments’ bigger and more encompassing command and data unit, installed by spacewalking astronauts in 2009.
Engineers successfully switched to the back-up equipment on Thursday, and the crucial payload computer kicked in.
Nasa said on Friday that science observations should resume quickly if everything goes well.
A similar switch took place in 2008 after part of the older system failed.
“Congrats to the team!” Nasa’s science mission chief Thomas Zurbuchen tweeted.
Launched in 1990, Hubble has made more than 1.5 million observations of the universe.
Nasa launched five repair missions to the telescope during the space shuttle programme, and the final tune-up was in 2009.
The administration plans to launch Hubble’s successor, the James Webb Space Telescope, by the end of the year.