A rare, powerful earthquake struck Morocco, sending people racing from their beds into the darkened streets and toppling buildings in mountainous villages and ancient cities not built to withstand such force. More than 1,000 people were killed, and the toll was expected to rise as rescuers struggled on September 9 to get through boulder-strewn roads to the remote areas hit hardest.

The magnitude-6.8 quake, the biggest to hit the North African country in 120 years, sent people fleeing their homes in terror and disbelief on September 8. One man said dishes and wall hangings began raining down, and people were knocked off their feet. The enormity of the destruction came into view in the daylight.

The quake brought down walls made from stone and masonry not designed to withstand quakes, covering whole communities with rubble and leaving residents picking their way precariously through remains. Rescuers worked through the night to find survivors buried in the dusty ruins.

A tent typically used for celebrations was being erected for shelter in the square of the impoverished mountain community of Moulay Brahim, where homes made of clay and brick were largely left uninhabitable. Fathers sobbed into phones telling loved ones about losing their children. Bodies covered with blankets lay in the health center next to a mosque as doctors pulled shards from people’s feet and treated surface wounds.

“There’s nothing to do but pray,” said Hamza Lamghani, who lost five of his closest friends.

People could be seen on state TV clustering in the streets of historic Marrakech, afraid to go back inside buildings that might still be unstable. Many wrapped themselves in blankets as they tried to sleep outside.

Marrakech’s famous Koutoubia Mosque, built in the 12th century, was damaged, but the extent was not immediately clear. Its 226-foot minaret is known as the “roof of Marrakech.” Moroccans also posted videos showing damage to parts of the famous red walls that surround the old city, a UNESCO World Heritage site.

At least 1,037 people died, mostly in Marrakech and five provinces near the quake’s epicenter, and another 1,204 people were injured, Morocco’s Interior Ministry reported on September 9. Of the injured, the ministry wrote, 721 were in critical condition.

“The problem is that where destructive earthquakes are rare, buildings are simply not constructed robustly enough to cope with strong ground shaking, so many collapse, resulting in high casualties,” said Bill McGuire, professor emeritus of geophysical and climate hazards at University College London. “I would expect the final death toll to climb into the thousands once more is known. As with any big quake, aftershocks are likely, which will lead to further casualties and hinder search and rescue.”

In a sign of the huge scale of the disaster, Morocco’s King Mohammed VI ordered the armed forces to mobilize air and land assets, specialized search and rescue teams and a surgical field hospital, according to a statement from the military. But despite an outpouring of offers of help from around the world, the Moroccan government had not formally asked for assistance, a step required before outside rescue crews could deploy.

Ayoub Toudite said he had been working out with friends at a gym in Moulay Brahim, which is carved into a mountainside south of Marrakech, when “we felt a huge shake like it was doomsday.” In 10 seconds, he said, everything was gone.

Rescuers were using hammers and axes to free a man trapped under a two-story building. People capable of squeezing into the tiny space were giving him water.

“We are all terrified that this happens again,” Toudite said.

The epicenter of the September 8 tremor was near the town of Ighil in Al Haouz Province, roughly 43.5 miles south of Marrakech. Al Haouz is known for scenic villages and valleys tucked in the High Atlas, and villages built into mountainsides.

Abderrahim Ait Daoud, head of the town of Talat N’Yaaqoub, told Moroccan news site 2M that authorities were working to clear roads in Al Haouz Province to allow passage for ambulances and aid to populations affected, but said large distances between mountain villages meant it would take time to learn the extent of the damage.

The Moroccan military deployed aircraft, helicopters and drones and emergency services mobilized aid efforts to the hardest areas, but roads leading to the mountain region around the epicenter were jammed with vehicles and blocked with fallen rocks, slowing rescue efforts. Trucks loaded with blankets, camp cots and lighting equipment were trying to region that hard-hit area, the official news agency MAP reported.

On the steep, winding switchbacks from Marrakech to Al Haouz, ambulances with sirens blaring and honking cars veered around piles of Mars-like red rock that had tumbled from the mountainside and blocked the road. Red Cross workers tried to clear a boulder blocking the two-lane highway.

World leaders offered to send in aid or rescue crews as condolences poured in from countries around Europe, the Middle East and a Group of 20 summit in India. The president of Turkey, which lost tens of thousands of people in a massive earthquake earlier this year, was among those proposing assistance. France and Germany, with large populations of people of Moroccan origin, also offered to help, and the leaders of both Ukraine and Russia expressed support for Moroccans.

The U.S. Geological Survey said the quake had a preliminary magnitude of 6.8 when it hit at 11:11 p.m., with shaking that lasted several seconds. The U.S. agency reported a magnitude 4.9 aftershock hit 19 minutes later. The collision of the African and Eurasian tectonic plates occurred at a relatively shallow depth, which makes a quake more dangerous.

Earthquakes are relatively rare in North Africa. Lahcen Mhanni, Head of the Seismic Monitoring and Warning Department at the National Institute of Geophysics, told 2M TV that the earthquake was the strongest ever recorded in the region.

In 1960, a magnitude 5.8 tremor struck near the Moroccan city of Agadir and caused thousands of deaths. That quake prompted changes in construction rules in Morocco, but many buildings, especially rural homes, are not built to withstand such tremors.

In 2004, a 6.4 magnitude earthquake near the Mediterranean coastal city of Al Hoceima left more than 600 dead.

The September 8 quake was felt as far away as Portugal and Algeria, according to the Portuguese Institute for Sea and Atmosphere and Algeria’s Civil Defense agency, which oversees emergency response.

Sam Metz and Mosa’ab Elshamy

Associated Press

MARRAKECH, Morocco

Mosa’ab Elshamy (AP)