SpaceX rocket has returned to Earth and the facilities it was launched from, marking the first-ever recovery of a spaceship and a key milestone for rocket reusability.

SpaceX Starship 42 launched from the company's Texas facilities on Friday, local time.

After deploying 26 Starlink satellites in orbit, it fired one of its engines to begin an atmospheric plunge.

It faced blistering heat as its orbital speed of some 27,000 kilometres per hour slowed to a supersonic freefall in the skies above the Texas facilities.

The spacecraft then reignited three engines to flip itself in a vertical position and steer itself toward the launch tower, where two mechanical "chopstick" arms clasped onto the spacecraft as it hovered in place.

The towering two-stage rocket's Super Heavy booster, the rocket's bottom half, had carried Starship 42 to space.

That booster failed to make a similar return to the launch pad some 10 minutes after lift-off, but the upper stage's successful return after orbiting Earth 14 times for more than 22 hours marked a key engineering milestone in the company's decade-long effort to develop a fully reusable rocket.

SpaceX's dominance in the global launch industry is centred on its workhorse Falcon 9 rocket, which has launched more than 700 times since 2010. 

That rocket's first stage is reusable, but its second stage — the part that delivers payloads into orbit — is discarded in the ocean after each flight.

With Starship, owner Elon Musk wants a rocket system that can fly to space and back like commercial aeroplanes, as he seeks to put humans on the Moon and eventually Mars.