The Libyan government has announced an immediate ceasefire in its offensive against rebels who have seized large areas of the country.
The announcement came as a coalition of Western and Arab nations prepared for air strikes against Libyan forces.
Before the ceasefire announcement, heavy fighting was continuing.
Rebels said government forces had been bombarding the western city of Misrata - but the government denied that this had continued after the ceasefire.
Military action short of an occupation was sanctioned by the United Nations Security Council on Thursday evening.
UN Security Council Resolution 1973 gave broad backing to taking military action against all threats to civilians, which could include bombing ground forces loyal to Libyan leader Colonel Muammar Gaddafi.
Libyan Foreign Minister Mussa Kussa said his country was obliged to accept the UN resolution and to observe the air exclusion zone that had been agreed.
"Libya has decided an immediate ceasefire and an immediate halt to all military operations," he said.
Later, Libyan government spokesman Mussa Ibrahim told Reuters news agency: "Libya has already implemented the ceasefire. We have not carried out any military operations today on Misrata or anywhere else in the country."
He added that Tripoli wanted the Turkish and Maltese authorities to "supervise and help implement the ceasefire".
The ceasefire announcement came only hours after Col Gaddafi had insisted that the Security Council had "no mandate" for such a resolution, "which we absolutely do not recognise".
"This is not a war between two countries that permits the council to intervene," he said in an interview on Portuguese television. The UN Charter "does not permit interference in domestic affairs", he added.
The Libyan military had previously warned that civilian and military activities in the Mediterranean would become "the target of a Libyan counter-attack" following any foreign operation.
'Actions not words'
US Secretary of State Hillary Clinton said the Libyan government would need to demonstrate it was implementing a ceasefire.
"We are going to be not responsive or impressed by words, we would have to see actions on the ground and that is not yet at all clear," she said.
"We will continue to work with our partners in the international community to press Gaddafi to leave and to support the legitimate aspirations of the Libyan people."
British Prime Minister David Cameron said Britain would judge Col Gaddafi "by his actions not his words".
"What is absolutely clear is the UN Security Council resolution said he must stop what he is doing, brutalising his people," Mr Cameron told the BBC. "If not, all necessary measures can follow to make him stop."
Mr Cameron had earlier said Britain was preparing to move Tornado and Typhoon fighter-bomber aircraft to bases near Libya. The British and French, along with some Arab allies, are expected to play a leading role in any initial air strikes.
French Foreign Minister Alain Juppe said everything was ready to launch military strikes, and that a ceasefire would need to cover the whole country.
"We have to analyse the conditions of the ceasefire," he told Reuters TV, adding that this would be examined at a summit in Paris on Saturday.
The announcement of a ceasefire was dismissed by a rebel commander in the eastern city of Benghazi, an anti-Gaddafi stronghold, who accused the Libyan leader of "bluffing".
Khalifa Heftir told reporters: "Gaddafi does not speak any truth... All the world knows that Muammar Gaddafi is a liar. He and his sons, and his family, and all those with him are liars."
The 15-member UN Security Council approved the resolution on Libya late on Thursday with 10 votes in favour, none against and five abstentions.
Russia and China - which often oppose the use of force against a sovereign country as they believe it sets a dangerous precedent - abstained rather than using their power of veto as permanent members.
If there is opposition to the regime in Tripoli, it has been silenced, either by fear, or by the prevailing atmosphere of patriotism, reports the BBC's Allan Little from the capital.
There is dismay and anger at the UN decision, adds our correspondent, with many seeing the rebellion in the east not as a popular uprising against dictatorship but as a criminal enterprise supported by foreign powers and aimed at plundering Libya's oil.
Col Gaddafi has ruled Libya for more than 40 years. An uprising against him began last month after long-time leaders of neighbouring Tunisia and Egypt were toppled.