Government spokesman Mussa Ibrahim accused the Western alliance of "deliberately targeting civilians," insisting there were no military targets anywhere near the residential neighbourhood of the capital that was hit.
He demanded that NATO end its "aggression" to pave the way for dialogue, after organisations including the the Arab League, the European Union and the United Nations highlighted the importance of "accelerating" political efforts to end a conflict now in its fifth month.
Journalists were taken to the Al-Arada district of Tripoli before 1 am (2300 GMT Saturday) to see rescue teams helped by bystanders desperately searching for survivors among the wreckage of a two-storey block of flats.
An AFP correspondent saw two bodies pulled from the rubble.
Journalists were then taken to a Tripoli hospital where they were shown the bodies of a woman and two toddlers that officials said were members of the same family and had died in the raid.
Ibrahim said he feared the death toll would rise as the building was home to at least 15 people.
There was no immediate word from NATO on the alleged air strike but if confirmed the civilian deaths would be an embarrassment for the alliance which has been leading the bombing campaign under a UN mandate to protect civilians.
"It is another night of massacre, terror and horror at the hands of NATO," the Libyan government spokesman charged.
Western leaders "are morally and legally responsible for these murders," Ibrahim said.
"This is not propaganda. It is not something that we can stage."
Libyan officials has been on the defensive over their credibility after they showed journalists a little girl being treated in hospital two weeks ago and said she had been wounded in a NATO air strike. A member of the medical staff said she had been injured in a traffic accident.
Ibrahim called on NATO to halt its "aggression" against Libya to pave the way for dialogue to end the conflict ravaging the North African nation.
"NATO is very good at attacking and killing people but it is very bad at starting dialogue," he said.
The alliance has acknowledged mis-hits in the past, most of them involving rebel fighters wrongly identified as loyalist troops.
Only Saturday NATO acknowleged that aircraft under its command had accidentally hit a rebel column near the oil refinery town of Brega on the front line between the rebel-held east and the mainly government-held west on Thursday.
"NATO can now confirm that the vehicles hit were part of an opposition patrol," it said in a statement.
"This incident occurred in an area of conflict between Kadhafi forces and opposition forces.
"We regret any possible loss of life or injuries caused by this unfortunate incident," NATO said.
On Friday, Prime Minister Baghdadi al-Mahmudi said NATO-led raids had hit a university and a hotel in Tripoli and accused the alliance of committing "war crimes and crimes against humanity."
NATO dismissed the claims as "outrageous."
"It is Kadhafi and his regime that have been systematically and brutally attacking the Libyan people," said spokeswoman Oana Lungescu.
The alleged civilian casualties in Tripoli come amid mounting international pressure on the alliance to seek a negotiated solution to the conflict as the frontlines between the rebels and the government show little movement despite the protracted bombing campaign.
After talks in Cairo on Saturday, the African Union, the Arab League, the European Union and the United Nations issued a joint statement underlining the importance of "accelerating the launch of a political process that responds to the legitimate aspirations of the Libyan people."
EU foreign policy chief Catherine Ashton attended the meeting along with outgoing Arab League chief Amr Mussa and African Union head Jean Ping, while UN chief Ban Ki-moon joined by live video link.
Ban said that the roots of a negotiating process were showing but that the international community needed to give a "consistent message" on a political solution with Kadhafi.
The UN chief's comments came after both the Libyan prime minister and Russian envoy Mikhail Margelov insisted that contacts were under way between the two sides despite furious denials by the rebels.
"Ask the Egyptians, French, Norwegians and Tunisians for information. They will tell you the truth," Mahmudi said. "We are sure of our meetings and everything has been recorded."
Margelov said after visiting Tripoli that Kadhafi's regime had forged multiple contacts with the Libyan rebels' National Transitional Council in foreign capitals including Berlin, Paris and Oslo.
But the NTC denied there were any talks.
"I can assure you there is and there was no negotiation between the NTC and the regime," said the council's head of international affairs, Mahmud Jibril.