The UN Security Council condemned Syria "in the strongest terms" over its deadly shelling of a border town in Turkey, but Prime Minister Recep Tayyip Erdogan said there were no plans to go to war.
Turkish artillery hit back at Syrian army positions on Wednesday night and again on Thursday, and the Turkish parliament gave its authorisation for further military action.
But on Friday, calm had returned to the border area and there were no further Turkish reprisals, monitors said, as Damascus apologised.
Turkey had demanded strong Security Council action after Syrian fire killed five of its nationals in the border town of Akcakale on Wednesday, including a mother and her three children.
After hours of haggling between Turkey's Western allies on the Security Council and longtime Syria backer Russia, the top UN body issued its statement, which although toughly worded was a rung down from a formal resolution.
"The members of the Security Council condemn in the strongest terms the shelling by the Syrian armed forces," the statement said.
The text also urged "restraint" and Guatemala's ambassador to the United Nations, the current council president, said this applied to both Syria and Turkey.
Nearly all of the strongly worded message, however, was aimed at Syria.
Saying the shelling "highlighted the grave impact the crisis in Syria has on the security of its neighbours and on regional peace," the council "demanded that such violations of international law stop immediately and are not repeated."
UN chief Ban Ki-moon urged "maximum restraint," warning of the risks for the entire region.
"The secretary general calls on all concerned to abandon the use of violence, exercise maximum restraint and exert all efforts to move toward a political solution," said his spokesman, Martin Nesirky.
Wednesday's incident marked the first time that Turkish civilians have been killed by Syrian fire since the start of an uprising in Syria against President Bashar al-Assad in March 2011.
Turkey retaliated by counter-shelling Syrian positions. Reports spoke of several Syrian soldiers killed, but the Syrian ambassador to the United Nations said two soldiers were only wounded.
The Turkish premier said that the authorisation given by parliament for further military action was not a mandate for war but said that his nation's borders and citizens would be defended.
"No country should dare test our determination on that," he said.
In Istanbul, around 1,000 mostly left-wing peace protesters chanted slogans against the government for the mandate, which they branded a tool for "an imperialist war".
The border region between Turkey and northern Syria was quiet on Friday, the Syrian Observatory for Human Rights reported, citing activists on the ground.
"There is nothing going on at the border now," Observatory director Rami Abdel Rahman told AFP by telephone.
In Washington, US State Department spokeswoman Victoria Nuland said the Turkish retaliatory fire had been an "appropriate" and "proportional" response.
However, Russia, which accuses the West of fuelling the conflict by helping rebels trying to oust Assad's regime, said the Syrian shelling had been "a tragic accident."
Turkish officials said Syria had apologised but Russian Foreign Minister Sergei Lavrov said it was "vital that Damascus states this officially."
Syria's ambassador to the United Nations said Damascus was not seeking an escalation in tensions with Turkey or other countries.
"The Syrian government has a key interest in maintaining good neighbourly relations with Turkey," ambassador Bashar Jaafari told reporters.
"In case of border incidents between any two neighbouring countries, governments should act wisely, rationally and reasonably."
But he called on the Turkish government to cooperate with Syria on controls to "prevent armed groups from infiltrating through this border" to stage attacks in Syria.
Syria has been pushing for a matching Security Council statement condemning a series of car bombs claimed by a jihadist group that killed almost 50 people in government-controlled areas in the heart of Aleppo on Wednesday.
Talks on a Russian draft were expected to take place later on Friday.
Inside Syria, a total of 170 people were killed in violence on Thursday -- 74 civilians, 48 rebels and 48 soldiers, the Syrian Observatory said.
Outside Damascus, clashes between the army and rebels left at least 21 members of Syria's elite Republican Guards unit dead, the Britain-based watchdog said.
In all, more than 31,000 people have been killed since the revolt against Assad's regime began nearly 19 months ago, according to the Observatory's figures.