Syrian troops pushed Islamic State group jihadists back from the ancient city of Palmyra on Sunday in fighting that left dozens dead and eased fears for the world heritage site.
The militants had seized the northern part of the modern town, Tadmur, in a major assault on Saturday but were driven out by troops and militia.
"We have good news today, we feel much better," antiquities chief Mamoun Abdulkarim told AFP by telephone.
"There was no damage to the ruins, but this does not mean we should not be afraid."
Provincial governor Talal Barazi told AFP that the army had recaptured northern districts of the town which the jihadists had overrun on Saturday.
"IS's attack was foiled," Barazi said.
He said the army was "still combing the streets for bombs," but that "the situation in the city and its outskirts is good."
The Syrian Observatory for Human Rights said there were still sporadic skirmishes but the army had reasserted its control.
"There are still clashes -- though not very fierce -- in the northern suburbs of al-Amiriyah," said Observatory director Rami Abdel Rahman.
He said the jihadists were still just a kilometre (less than a mile) away from the UNESCO-listed heritage site and its adjacent museum which houses thousands of priceless artefacts.
"IS is still present outside the city, to the south and east," Abdel Rahman said.
The jihadists launched a lightning offensive across the desert last week from their stronghold in the Euphrates Valley to the east, triggering ferocious fighting with the army, which has a major base just outside the oasis town.
At least 23 regime loyalists and 29 jihadists were killed as IS overran northern parts of the town on Saturday, the Britain-based Observatory said.
Barazi said the army had killed "more than 130 jihadists." He gave no figure for the army's losses.
The governor said Tadmur's peacetime population of 70,000 had been swamped by an influx of civilians fleeing the IS advance.
Four IS leaders killed
"We are taking all necessary precautions, and we are working on securing humanitarian aid quickly in fear of masses fleeing from the city," Barazi said.
Abdulkarim said he remained concerned for Palmyra in light of the destruction wreaked by IS on pre-Islamic sites like Nimrud and Hatra in neighbouring Iraq.
The antiquities chief said he had been "living in a state of terror" that IS would destroy the 1st and 2nd century temples and colonnaded streets that are among Palmyra's architectural treasures.
The jihadists tightened their control of the countryside outside Tadmur, seizing two checkpoints in the Haql al-Hail oil field, the Observatory said.
Troops and militia were fighting back in a bid to prevent IS from capturing the field which could offer it a significant additional source of black market revenue.
A US raid late on Friday on one of Syria's largest oil fields left 32 IS members dead, including four leading officials, Abdel Rahman told AFP.
"The US operation killed 32 members of IS, among them four officials, including IS oil chief Abu Sayyaf, the deputy IS defence minister, and an IS communications official," he said.
US officials have said "about a dozen" people were killed in the operation, which was conducted by Iraq-based US commandos in a bid to capture Abu Sayyaf.
Abdel Rahman said three of the four leading officials killed in the raid were from north Africa, but that the IS communications official was Syrian.
President Barack Obama personally approved the special forces operation, which was a rare use of "boots on the ground" in the US-led campaign against the jihadists that has been waged almost entirely from the air.