At least 24 people have been killed and more than 70 injured in a blast outside a mosque in north-west Pakistan.
The explosion happened in the city of Parachinar, a mainly Shia Muslim area on the Afghan border.
Reports say a car packed with explosives was left near the women's entrance of the mosque as people gathered for Friday prayers.
A faction of the Pakistani Taliban (TTP), Jamaat-ul-Ahrar (JuA), said it had carried out the attack.
Many shops and vehicles close to the mosque were damaged in the powerful blast.
"People were screaming for help... When I looked back everything was filled with dust," shopkeeper Sardar Hussain told AFP news agency.
Kamran Ali told the Associated Press news agency he was inside his shop when the blast happened.
"My shop partially collapsed and I was unable to move for the next 30 minutes or so, and then residents brought me to hospital," he said.
The Pakistani Army sent a helicopter to help take the injured to hospital.
A doctor at a local hospital said an appeal was being made for blood donors to help treat the wounded.
"Patients are being brought to us in private cars and ambulances and we have received over three dozen patients so far," the doctor told Reuters news agency.
'Security failures' - By M Ilyas Khan, BBC News, Islamabad
This bombing in Parachinar, in Kurram district, is the second since January, and just as deadly. Many among the injured are said to be in a critical state.
Kurram is the only Shia Muslim region in a predominantly Sunni country. Sunni hardliners, currently operating through different Taliban factions including the Islamic State group, consider them heretics and worthy of death. These groups have sanctuaries in Afghan and Pakistani areas surrounding Kurram, and have launched frequent attacks against civilians in Parachinar.
Locals blame the military for security failures and allege its policy of tolerating some Sunni militant groups has given extremists a new lease of life. They also point to the illegal border trade in the region, which they say goes on under the watch of the military and creates openings for militants to infiltrate.
Prime Minister Nawaz Sharif condemned the attack, saying his government would keep working to "eliminate the menace of terrorism".
It was followed by protests in Parachinar as angry crowds accused the security forces of failing to protect them.
Parachinar was also targeted in January, when a bomb blast in a vegetable market killed at least 20 people. That attack was also claimed by JuA.
Nationally, Pakistan has seen an upsurge in violence since the beginning of the year. Last month, more than 80 people were killed in an attack at a Sufi shrine in Sindh province. The so-called Islamic State militant group said it carried out that attack.
Parachinar is the capital of the Kurram, one of Pakistan's seven tribal districts.
These areas are governed according to local laws and customs, and are known for sectarian clashes between Sunni and Shia Muslim groups.