A new mission called AIDA aims to demonstrate the technology needed to deflect an asteroid. Photograph: ESA-AOES Medialab.

Science fiction author Larry Niven once joked: "The dinosaurs became extinct because they didn't have a space programme." He meant that if we see an asteroid heading our way, we can launch a rocket to intercept it. But just how do we deflect an asteroid?

Alan Fitzsimmons, University of Belfast, is part of a European Union project called NEOShield. It studies the ways in which dangerous asteroids could be deflected.

"There are three ways to deflect a dangerous asteroid: the gently pull, the swift kick and nuking it," says Fitzsimmons. Which method is best depends on the asteroid's size, composition, orbit, and crucially, how much warning we get. Typically, warning times of a decade or so would be required.

With plenty of warning, the gentle pull may be all that is needed. In this scenario, you send the heaviest spacecraft you can launch to "hover" close to the dangerous asteroid. The tiny gravitational pull that the spacecraft produces on the asteroid then adds up over many years to shift it off collision course. It's a concept known as the gravity tractor.

The swift kick actually involves a collision. You hit the asteroid with a heavy spacecraft that instantaneously changes its orbit. The more warning you have, the smaller the kick you need to give it. Observations can quickly show whether the method has worked or whether another kick is needed.

Finally, if things are desperate, nuke it. This can provide the biggest kick of all. But don't shatter the asteroid. The last thing you want to do is break it up. That turns a cannonball into buck shot without significantly changing its orbit.

Instead, a nearby nuclear explosion would evaporate the surface layers of the asteroid. As the vaporised rock jets into space, the asteroid would be pushed in the opposite direction.

The European Space Agency and colleagues at Johns Hopkins University Applied Physics Laboratory, Maryland, are currently studying a mission to test the middle one, the swift kick.

Called the Asteroid Impact and Deflection mission (AIDA), the European Space Agency issued a call for experimental ideas just a few weeks ago. The idea is simple, two spacecraft will launch. Only one will survive.

The observer spacecraft will watch as the impactor spacecraft slams into an asteroid, attempting to move it by a tiny amount.

This is not the first time that Esa has studied an asteroid deflection mission. In the mid-2000s, there was a proposed mission called Don Quijote. Like AIDA, it was composed of two spacecraft: one to hit an asteroid, the other to watch.

Didymos consists of two asteroids, 800 metres and 150 metres across, in orbit around one another. Hitting the smaller of the two asteroids will change its orbit around the larger one.

Johns Hopkins University will provide the impactor spacecraft. Esa will provide the observing spacecraft. A decision about whether to build and launch the mission will be taken once the studies are finished.

Esa's telescope is the Fly's Eye Telescope, funded last November to the tune of €7m. A prototype is currently being built in Italy but the eventual telescope could be sited on Tenerife.

Nasa's project costs a similar amount and is known as Atlas, which stands rather ominously for Asteroid Terrestrial-Impact Last Alert System. The "last" in that name means that it would not find smaller asteroids in time to deflect them but it would give us days or weeks of warning to evacuate the target area.

According to the University of Hawaii team behind Atlas, the system could offer a one-week warning for a 45-metre diameter asteroid or "city killer" and three weeks for a 120-metre diameter "county killer".

"That's enough time to evacuate the area of people, take measures to protect buildings and other infrastructure, and be alert to a tsunami danger generated by ocean impacts," says astronomer John Tonry in a press release.

There is no quick fix to deflecting asteroids. Friday's events, in which more than 1,000 people were injured, was a wake up call that the threat is every bit as real as the natural disasters we are more used to dealing with.