Boeing's Starliner spacecraft made a soft touch down in the desert of New Mexico early Sunday. It marked the end of a tense two-day effort to return the vehicle to Earth after unexpected issues plagued its inaugural flight to orbit, forcing it to make an early return.

The spacecraft launched an uncrewed test flight on Friday but had to abort its mission to dock with the International Space Station when it failed to put itself on the right trajectory.

Starliner's return on Sunday was a win for Boeing because experts will be able to retrieve valuable data about whether the spacecraft, which is designed to fly NASA astronauts to the space station, can execute a safe landing after returning from space.

Boeing has worked for the past decade to prepare Starliner for crewed missions after NASA asked the private sector to design spacecraft capable of ferrying astronauts to the ISS after retiring the space shuttle program.

NASA allotted Boeing $4.2 billion in 2014 for Starliner development and anticipated it would to be ready by 2017. But it's suffered numerous delays and development setbacks.

The mission Starliner undertook this week was a massive milestone: It was expected to be the last major test before the craft was finally ready to fly NASA astronauts.

Starliner successfully launched into space aboard a rocket Friday morning, but after detaching from the launch vehicle, it failed to put itself on the correct path to the space station.

Officials attributed the problem to an unsynchronized clock: An error in Starliner's onboard timekeeping system caused the spacecraft to miscalculate where the vehicle was and when it should conduct a series of maneuvers to stay on track.

The timing error triggered a ripple effect of other issues. It prevented ground control from establishing a connection with the vehicle for about eight crucial minutes. During that time, the vehicle burned the fuel it would have needed to comfortably correct course back toward the International Space Station, which orbits about 250 miles above Earth.

The mishap prevented Boeing from demonstrating that Starliner can safely dock with the ISS, a feat that requires the spacecraft to complete precise maneuvers in order to latch itself onto a designated port — all while traveling more than 17,000 miles per hour.

But with that option off the table, Boeing officials decided instead to put Starliner on a path back home so it could focus on proving the spacecraft can safely guide itself to a designated landing site in New Mexico.

The spacecraft on Sunday guided itself back through the Earth's atmosphere, deployed parachutes and a halo of air bags, and made a gentle touchdown.

Early reports from Boeing officials Sunday morning said the spacecraft was in good health. They're currently working to inspect the vehicle and offload the cargo Starliner carried on its test mission. That includes an anthropomorphic test dummy, named after the World War II icon Rosie the Riveter, which was equipped with dozens of sensors to measure the G-forces future passengers may experience aboard a Starliner flight.

Officials are expected to spend the coming weeks reviewing data from this mission. It's not clear yet if NASA will require Boeing to launch another uncrewed demonstration flight before it allows passengers on board.

The space agency's administrator, Jim Bridenstine, who described the landing as an "absolute bullseye," has said he would consider allowing the company to move forward with crewed flights. He noted that if astronauts had been on board this test flight they may have been able to override the faulty autonomous system and taken manual control of spacecraft.

Mike Fincke and Nicole Mann, two of the astronauts slated to fly on Starliner's first crewed mission, confirmed that suggestion during a press conference Friday.

"We train extensively for this type of contingency," Mann said. "This vehicle has a new level of automation that we've never seen before. And what we're doing is testing that automation, and that's why you have test pilots on board" early missions.

But NASA wants Starliner to be able to function without human input. Mann and Fincke are specially trained test pilots, but Starliner is intended to provide rides for all types of astronauts — including scientists and research specialists.