A spacecraft blasted off on Monday to investigate the scene of a cosmic crash.

The European Space Agency’s Hera spacecraft rocketed away on a two-year journey to the small, harmless asteroid rammed by Nasa two years ago in a dress rehearsal for the day a space rock threatens Earth.

Launched by SpaceX from Cape Canaveral, it is the second part of a planetary defence test that could one day help save the planet.

The 2022 crash by Nasa’s Dart spacecraft shortened Dimorphos’s orbit around its bigger companion, demonstrating that if a dangerous rock was headed towards Earth, there is a chance it could be knocked off course with enough advance notice.

Scientists are eager to examine the impact’s aftermath up close to know exactly how effective Dart was and what changes might be needed to safeguard Earth in the future.

“The more detail we can glean the better as it may be important for planning a future deflection mission should one be needed,” University of Maryland astronomer Derek Richardson said before launch.

Researchers want to know whether Dart — short for Double Asteroid Redirection Test — left a crater or perhaps reshaped the 500-foot (150-metre) asteroid more dramatically.

It looked something like a flying saucer before Dart’s blow and may now resemble a kidney bean, said Mr Richardson, who took part in the Dart mission and is helping with Hera.

Dart’s hit sent rubble and boulders flying off Dimorphos, providing an extra kick to the impact’s momentum. The debris trail extended thousands of miles (more than 10,000 kilometres) into space for months.

Some boulders and other debris could still be hanging around the asteroid, posing a potential threat to Hera, said flight director Ignacio Tanco.

“We don’t really know very well the environment in which we are going to operate,” said Mr Tanco. “But that’s the whole point of the mission is to go there and find out.”

European officials describe the 400 million-dollar (£306 million) mission as a “crash scene investigation”.

A SpaceX Falcon 9 rocket lifts off from the Cape Canaveral Space Force Station
A SpaceX Falcon 9 rocket lifts off from the Cape Canaveral Space Force Station, carrying a European spacecraft to an asteroid (John Raoux/AP)

Hera “is going back to the crime site and getting all the scientific and technical information”, said project manager Ian Carnelli.

Carrying a dozen science instruments, the small car-sized Hera will need to pass Mars in 2025 for a gravity boost, before arriving at Dimorphos by the end of 2026. It is a moonlet of Didymos, Greek for twin, a fast-spinning asteroid that is five times bigger.

At that time, the asteroids will be 120 million miles (195 million kilometres) from Earth.

Controlled by a flight team in Darmstadt, Germany, Hera will attempt to go into orbit around the rocky duo, with the flyby distances gradually dropping from 18 miles (30 kilometres) all the way down to a half a mile (one kilometre).

The spacecraft will survey the moonlet for at least six months to ascertain its mass, shape and composition, as well as its orbit around Didymos.

Before the impact, Dimorphos circled its larger companion from three-quarters of a mile (1,189 metres) out. Scientists believe the orbit is now tighter and oval-shaped, and that the moonlet may even be tumbling.

Two shoebox-sized Cubesats will pop off Hera for even closer drone-like inspections, with one of them using radar to peer beneath the moonlet’s boulder-strewn surface.

Scientists suspect Dimorphos was formed from material shed from Didymos. The radar observations should help confirm whether Didymos is indeed the little moon’s parent.

The Cubesats will attempt to land on the moonlet once their survey is complete. If the moonlet is tumbling, that will complicate the endeavour. Hera may also end its mission with a precarious touchdown, but on the larger Didymos.

Neither asteroid poses any threat to Earth — before or after Dart. That is why Nasa picked the two for humanity’s first asteroid-deflecting demo.

Leftovers from the solar system’s formation 4.6 billion years ago, asteroids primarily orbit the sun between Mars and Jupiter in what is known as the main asteroid belt, where millions of them reside. They become near-Earth objects when they are knocked out of the belt and nearer to Earth.

Nasa’s near-Earth object count currently tops 36,000, almost all asteroids but also some comets. More than 2,400 of them are considered potentially hazardous to Earth.