Nineteen people died when a suicide bomber rammed an explosives-laden truck into a police station in north-west Pakistan.
Eleven policemen and four passing schoolchildren were among those killed in the attack in Lakki Marwat town, in Khyber Pakhtunkhwa province.
The Pakistani Taliban said they carried out the bombing.
Last week, the group said it had carried out several attacks on Shia Muslims that left more than 100 dead.
Meanwhile at least four al-Qaeda militants have been killed near the town of Miranshah, officials say.
Their car was hit by two missiles fired from a suspected US drone in the area of Dattakhel, an area which officials say is an al-Qaeda safe haven near the Afghan border.
The area is controlled by fighters loyal to Taliban commander Hafiz Gul Bahadur, whom officials say has been sheltering al-Qaeda and Taliban militants.
'Dust and darkness'
More than 40 people were wounded in Monday's blast at Lakki Marwat.
The bomber reportedly struck a school van before ramming the rear wall of the police station; the building collapsed.
A neighbourhood shop and mosque were also damaged.
Rescue workers and police officials dug through the rubble to reach those trapped.
Police sub-inspector Ameen Khan Marwat was pulled out alive.
"All the morning staff were there because they had not yet left for their duties," he said.
"Some were still lying around, others were getting ready for duty when the blast occurred.
"Suddenly there was dust and darkness all around, and after that we had no idea where anyone was or what had happened to the others. It was sheer destruction all over."
As well as the four schoolchildren, the dead included a retired teacher, reports the Associated Press of Pakistan.
"Seventeen dead bodies and 45 injured have been brought to our hospital," Dr Ghulam Ali, of Lakki Marwat's main hospital, told the news agency AFP by telephone.
The Pakistani Taliban claimed they carried out the attack in a telephone call to the AP news agency.
They said that police were targeted because they had been encouraging residents to set up militias - known locally as lashkars - to fight the militants.
The Taliban pledged to carry out more attacks unless the militias disbanded.
Prime Minister Yousuf Raza Gilani condemned the latest bombing.
"It goes to show that the terrorists have no creed except bloodshed and chaos, and are desperately carrying out their agenda regardless of the precarious conditions," he told a meeting of provincial officials.
"I want to stress today that we shall never let their nefarious designs succeed and will eliminate them."
Pakistan's security forces have been fighting Taliban and al-Qaeda militants based in the north-west of the country for several years. Members of the Afghan Taliban are also based in the region.
Last week, more than 100 people were killed in suicide bombings at Shia minority processions in Pakistan. On Friday, an attack in Quetta killed 73 people, two days after blasts killed 35 people in Lahore.
The town of Lakki Marwat has previously been the scene of huge bomb attacks by militants, mainly on security personnel and tribesmen allied to them.
The police chief of Lakki Marwat district was killed in a suicide bombing several months ago.
The biggest attack in the town was on New Year's Day 2010, when more than 100 people died after a suicide bomber blew up a pick-up truck, after crashing into a crowd watching a volleyball match.
Nearly 9,000 people died across Pakistan in militant-related violence between 2007-09, according to the country's independent human rights commission.
The BBC's Syed Shoaib Hasan in Karachi says that since January this year - when the army announced that its resources in the north-west were stretched too thinly - the Taliban has regrouped and strengthened itself.
Our correspondent says that once again they have the ability to carry out attacks on targets across Pakistan following setbacks over the last two years in Swat and Waziristan.