ISLAMABAD, Pakistan — In the deadliest attack on the Pakistani capital in more than five years, a powerful explosion ripped through a crowded market in Islamabad on Wednesday, killing at least 22 people and suggesting that, after a long stretch of relative calm, the city was back in the firing line of the country’s militants.

The bomb, which the police said had been hidden in a crate of guava and possibly triggered by remote control, went off in the early morning at a wholesale fruit market on the edge of the city. Video on television showed the devastating aftermath — charred debris, shattered carts and bloodstained fruit — while witnesses spoke of seeing dismembered limbs and bodies flung high into the air. At least 100 people were reported to have been injured.

It was the deadliest assault in the capital since the bombing of the Marriott Hotel that killed 54 people in September 2008, one of a barrage of attacks that year and the next in which Islamist militants waged their terrorist campaign directly on Islamabad. For many shocked residents, the market bombing on Wednesday recalled that time of siege. But the question of which group planted the bomb — and to what end — became mired in a fog of claims and counterclaims throughout the day.

Immediately after the attack, a spokesman for the Pakistani Taliban said that the group had nothing to do with it. He criticized the violence against civilians — the group’s stock in trade since its formal emergence in 2007 — and insisted that the Taliban were observing a cease-fire until Thursday in support of peace talks with the government.