Media playback is unsupported on your device Media caption Dramatic video shows buildings being knocked down

More than 380 people have been confirmed dead after a tsunami triggered by a magnitude 7.5 earthquake hit an Indonesian city on Friday.

Waves up to 3m (10ft) high swept through Palu on Sulawesi island.

Video on social media shows people screaming and fleeing in panic and a mosque among the buildings damaged.

Strong aftershocks rocked the city on Saturday. Thousands of homes have collapsed, along with hospitals, hotels and a shopping centre.

Rescue efforts are under way, though hampered by a major power cut. The main road to Palu has been blocked due to a landslide, and a key bridge is out of action.

'Many bodies along the shoreline'

Indonesia's disaster agency said at least 384 people had been killed, but the number is expected to rise. At least 540 have been injured, and 29 are listed as missing.

Image copyright Reuters Image caption Locals check bodybags in the streets of Palu as they search for lost relatives

"Many bodies were found along the shoreline because of the tsunami, but the numbers are still unknown," Sutopo Purwo Nugroho, a spokesman for the agency, told Reuters.

"When the threat arose yesterday, people were still doing their activities on the beach and did not immediately run and they became victims," he told a news briefing.

"The tsunami didn't come by itself - it dragged cars, logs, houses - it hit everything on land."

Some survived by climbing 6m (18ft) trees to escape the huge waves, the spokesman said.

Image copyright Antara Foto/Rolex Malaha via Reuters Image caption Homes, hotels, and shopping centres have collapsed in the "extensive" damage, officials said

A less powerful quake earlier on Friday had killed at least one person and injured at least 10 in the smaller fishing town of Donggala.

In Palu, hundreds of people had been preparing for a beach festival that was due to start on Friday night.

The city's main hospital was damaged in the quake, and TV footage showed dozens of injured people being treated outside in makeshift medical tents.

Image copyright AFP/Getty Images Image caption Medical teams are treating patients in the open air

Image copyright AFP Image caption At least 384 people have been killed in the quake

Palu and Donggala are home to more than 600,000 people. President Joko Widodo said troops were en route to the area to reinforce rescue teams and help retrieve bodies.

The main airport in Palu has been closed since the tsunami hit. A minister said the runway had been damaged but that it was hoped helicopters would still be able to land.

The country's military is sending cargo planes of relief aid from the capital, Jakarta.

Officials are urging locals not to enter their homes and to sleep away from buildings, due to the risk of aftershocks.

Image copyright Antara Foto/Reuters Image caption Relief aid is packed into a military plane bound for Palu

Image copyright Reuters Image caption Indonesia's disaster agency said some people scaled trees to escape the huge waves

The earthquake hit just off central Sulawesi at a depth of 10km (6.2 miles) just before 18:00 on Friday (10:00 GMT), the US Geological Survey said.

A tsunami warning was issued, but lifted within the hour. Indonesia's meteorological agency has been criticised for its response, but officials said the waves struck while the warning was in place.

Dramatic video of the tsunami hitting Palu shows the high waves sweeping away several buildings and then the large tilted mosque in the town, about 80km from the quake's epicentre.

"The situation is chaotic, people are running on the streets and buildings collapsed. There is a ship washed ashore," said Dwikorita Karnawati, head of Indonesia's meteorology and geophysics agency.

A 2004 tsunami triggered by an earthquake off the Indonesian island of Sumatra killed 226,000 across the Indian Ocean, including more than 120,000 in Indonesia.

Indonesia is prone to earthquakes because it lies on the Ring of Fire - the line of frequent quakes and volcanic eruptions that circles virtually the entire Pacific rim.

More than half of the world's active volcanoes above sea level are part of the ring.

Just last month, a series of deadly earthquakes struck the Indonesian island of Lombok. The biggest, on 5 August, killed more than 460 people.