A shallow 5.1-magnitude earthquake has struck the Ecuadorian capital Quito, triggering landslides that killed at least two people and violently shaking buildings and homes.

Another eight people were injured and three others trapped in the landslides at quarries on the outskirts of Quito, the country's risk management agency said on Twitter.

Read more:
* China quake kills at least 367
* Remoteness of region hampers China quake effort
* One dead after 6.3-magnitude quake in Mexico
* Think about unthinkable disasters - Fukushima study

A landslide also engulfed a vehicle on a road north of the city, but the driver escaped unharmed, rescue workers said.


Authorities closed roads around the capital in case of more landslides, and also shut Quito airport.

The quake lasted more than 20 seconds and caused panic in Quito, where residents evacuated buildings after it struck at 2.58pm on Tuesday (7.58 Wednesday NZT).

Watch: Strong Quake kills 367 in China

"I was talking on the phone with my daughter and suddenly the line went dead. I thought the house was falling down," Laura Flores, a resident of Quito's northern Carcelen district, said.

She added the quake had opened a crack in one wall of her house and caused several plates to fall and break.

The country's Geophysics Institute said the quake occurred at a depth of five kilometres and was followed by a forceful aftershock. It warned that more small aftershocks were possible.

Emergency services said the epicentre was near Mitad del Mundo, a tourist attraction at the equator where a monument is being built at the dividing line between the northern and southern hemispheres.