Another eight people were wounded and three others trapped due to landslides on the outskirts of Quito, it added.
"Firemen are working to evacuate the wounded and to find and rescue the people who are trapped," the government's National Risk Control Agency said via Twitter, without giving details.
The Ecuadorian government said they have closed roads around the capital and shut the Quito airport in case of more landslides.
The quake occurred at 14:58 local time (1958 GMT). The U.S. Geological Survey said the moderate quake was only 7.7 kilometers deep, with its epicenter located 22 km northeast of Quito, a city of some 1.6 million inhabitants.
People in Quito felt the effects obviously and buildings swayed when the earthquake hit. A second quake occurred at 15:02 local time with a magnitude of 4.1 with a depth of 5.46 kilometers.
This is the second major quake felt in Ecuador's capital over the past four days.