Many buildings have been flattened and almost 100 people killed after an undersea earthquake struck off the coast of Aceh province in northern Indonesia, the site of the devastating quake and tsunami in 2004.
Residents were sent running into the streets after the 6.5-magnitude quake struck at about 5am local time, and remain reluctant to return home amid fears of aftershocks.
The US Geological Survey measured the quake at a depth of just 8.2km, 19km south-east of the coastal town of Sigli. Buildings shook in the provincial capital Banda Aceh.
No tsunami warning was issued, but at least five aftershocks were felt in the hours after the initial quake, the Indonesian disaster management agency said.
The death toll began at 25 and continued to rise throughout Wednesday. At 4pm local time, Aceh army chief Major General Tatang Sulaiman said the toll had jumped to 97 as more bodies were pulled from the rubble.
Indonesian search and rescue teams used earth movers to clear debris, pulling at least four people out of the wreckage alive.
The Indonesian government declared a two-week emergency period in Aceh and some aid was already reaching hard-hit areas.
Earlier Khairul Nova, an official at the Aceh search and rescue agency, said: "Dozens are missing but we don't have accurate data on the total yet."
Aceh, on the northern tip of Sumatra island, was devastated by a massive 9.2-magnitude earthquake and tsunami centred on its western coast near the provincial capital, Banda Aceh, on 26 December 2004.
More than 120,000 people were killed in Aceh alone.
Images on TV and social media on Wednesday morning showed victims being rushed to hospital, flattened buildings and fallen electricity poles, and people gathering outside at street corners.
Aceh's disaster mitigation agency said more than 600 people were injured.
"The earthquake was felt strongly and many people panicked and rushed outdoors as houses collapsed," said Indonesia's National Disaster Mitigation Agency spokesman Sutopo Purwo Nugroho.
A volunteer for the Indonesian Red Crescent in Pidie Jaya regency in Aceh described scenes of heavy damage and said many people had been injured.
"There isn't enough medical staff around," the Red Crescent's Muklis, who like many Indonesians uses one name, told TVOne.
More than 200 shops and houses were either severely damaged or destroyed by the quake, officials said, and classes for some 10,000 schoolchildren were disrupted.
In addition, some 14 mosques collapsed and one hospital was damaged, Nugroho told a news conference.
Aiyub Abbas, the chief of Pidie Jaya district, said there was an urgent need for emergency supplies.
Zunaidi, a village chief in Pidie Jaya, said about 1,700 people from the village moved to a temporary shelter at an Islamic boarding school about six miles south of Meureudu town.
He said most took shelter because they feared aftershocks could knock down their houses, which were partially damaged.
"We are still afraid to return home because of aftershocks, downpours and blackouts," said Zunaidi, who goes by a single name. The boarding school was providing generators, food and medicine, but people complained of a lack of clean water and baby food, he said.
Many residents feared a repeat of the devastating 2004 quake and subsequent tsunami. Fitri Abidin, a woman who lives on the coast in the worst-hit epicentre of the Pidie Jaya district, told the Reuters news agency she fled with her husband and children after the quake jolted the family awake early Wednesday.
They stayed on higher ground for several hours until authorities reassured them there was no tsunami risk.
She said: "It terrified me. I was having difficulty breathing or walking. We ran to a nearby hill, because our house is near a beach. We were afraid a tsunami can come at any time."