GILI TRAWANGAN, Indonesia — On the evening the earthquake struck the tiny island of Gili Trawangan, it was easy to panic. The ground swayed and the lights went out. Walls fell over and windows broke. At least one small hotel collapsed.
The government issued a tsunami warning, and thousands of tourists and workers rushed to safety atop the island’s only hill. The warning was canceled soon after but the refugees stayed put through the night, tormented by aftershocks and barely sleeping.
The next day, hundreds of anxious tourists and workers crowded the main beach on Gili Trawangan and waited hours for rescue boats to arrive. Videos of the scene — and foreigners’ complaints of a slow government response — went viral.
“When the earthquake happened, everybody was in a panic,” said Guntur Sakti, a spokesman for Indonesia’s Tourism Ministry. “It was even more chaotic when there were rumors about a tsunami. People wanted to flee. But to expect us to provide boats to evacuate them right at that moment, that was not possible.”
The quake that struck Lombok Island and the three nearby Gili islands on Sunday left at least 259 people dead and displaced more than 270,000. The worst damage was in North Lombok, where entire villages were destroyed. The United States Geological Service put the magnitude of the quake at 6.9.
The Indonesian authorities say that no foreigners were among the dead. But one enduring image of the disaster will be the crowds of foreign tourists waiting at the beach to board rescue vessels.
Some hotels in the stricken area have continued operating despite aftershocks, including one Thursday, and others have reopened. Other shop and hotel operators hope to be back in business in weeks or months.
But it may take longer to persuade large numbers of tourists to return.
“It is easier to restore the electricity than the reputation of the islands,” said Sander Buis, who runs the Oceans 5 dive resort on Gili Air, another of the Gili islands.
Over the years, Indonesia has been developing Lombok and the three nearby Gilis — Trawangan, Meno and Air — as tourist destinations. Lombok, a short flight from Bali, is less crowded and its white-sand beaches are more alluring.
One of the more popular areas is Senggigi, a coastal strip on the west side of Lombok, where a number of high-end resorts have sprung up in recent years. Many of them suffered damage from the quake.
After the quake hit, hotel managers in Senggigi evacuated their hotels and led guests up into nearby hills, where they spent the night.
The next day, many visitors tried to leave Lombok but there were not enough flights. Hundreds of tourists camped out in the airport terminal and in the lobbies of nearby hotels for two days as they waited.
The Sheraton Senggigi Hotel, which was one of the first major hotels built in the area, closed because of earthquake damage. Most of the guests chose to leave the island rather than accept new lodging. It was unclear when the hotel would reopen.
“In light of the recent earthquakes that took place in Lombok, guests at the Sheraton Senggigi Hotel have been evacuated,” said Christopher Chung, the Indonesia sales director for Sheraton’s parent company, Marriott International.
The three Gili islands lie off Lombok’s coast just north of the Senggigi beach. The two smaller islands, Gili Air and Gili Meno, sit barely above sea level. Neither have hills.
After the quake, tourists and locals on Gili Air gathered in an open field so they wouldn’t be hit by falling objects.
“If a tsunami comes, bummer,” said Yann Dumas, manager of the Freedive Flow diving school.
On Gili Trawangan, visitors and locals were not so fatalistic.
Some foreign tourists were spooked by the sound of waves crashing on the beach as they rushed up the hill. Aftershocks kept everyone on edge through the night.
“We sat and prayed,” said Lala Intan Komala, a shop clerk on the island whose family home in North Lombok was destroyed. “No one dared to go to sleep.”
Many local workers, hearing about the deaths of relatives and the destruction of their villages, were anxious to return home. Foreign tourists, fearful of tsunamis, were similarly apprehensive.
Some tourists complained of long waits and pushing and shoving as evacuees boarded the first boats. A few tourists offered local boat captains large sums to take them off the island rather than wait for free government rescue boats.
“The panic and chaos made people willing to do anything to get what they want, including offering to pay any amount to be transported,” said Mr. Guntur, the Tourism Ministry spokesman.
Compared with the destruction in North Lombok, the Gilis fared well.
Many buildings on Gili Trawangan are damaged but look as if they could be repaired.
“As you can see, it’s not that bad,” said Jennifer McKay, an American who manages the Pesona Beach Resort and Spa. “A lot of the tourists just wanted to get home. Who can blame them?”
Nearly a week later, about 100 people, mostly Indonesians, are still camping out on Gili Trawangan’s dusty hilltop 200 feet above sea level.
Herman, a boat captain who like many Indonesians goes by one name, said his group of about 30 relatives and friends planned to stay on the hill for three more weeks, when they believe the quake danger will be reduced.
At midday, most of them were sprawled on mats and blankets, enjoying a cool breeze under the shade of a large tree. A group of goats foraged nearby.
“We don’t really need help for the moment,” he said. “We are very happy here.”
Mr. Guntur said that barring further quakes, most tourist facilities on Lombok could be repaired relatively quickly. But the work on the Gilis will be slower because many workers must tend to their families in North Lombok, he added.
In all, the government evacuated more than 2,000 foreign tourists from the three Gili islands.
“The criticism came from people’s psychological condition,” he said. “The crude comments were because everybody wanted to get on the boat first.”
He said it would take time to counter the negative information and restore the region’s reputation.
“The social media posts are more harmful than the physical damage,” he said.