A suspected Islamic militant blew himself up among police guarding a court on Thursday, killing 24 people and wounding scores more, in the first major attack in Pakistan since the assassination of opposition leader Benazir Bhutto.

The blast at Lahore High Court, minutes before a planned anti-government rally by lawyers, was a bloody reminder of the security threats facing the country ahead of Feb. 18 elections.

• Click here to view photos (WARNING: GRAPHIC).

Over the past three months there have been at least 20 homicide bombings that have killed 400 people, many of them security forces — the most intense period of terror attacks since Pakistan allied with the United States in its war against Al Qaeda in 2001.

Police said the attacker walked into a group of around 70 officers in riot gear outside the courtroom and detonated explosives on his body, sending a shower of shrapnel that left mangled bodies sprawled in pools of blood on the street. All but three of the dead were police officers.

A slain horse lay beneath a toppled cart. Police boots, riot shields and helmets littered the street.

"There was a huge bang," said Munrian Bibi, 60, a school cleaner caught in the blast as she headed home from work. "I saw people falling on ground crying for help. I don't know what saved my life from that hell," she said in hospital where she was treated for leg wounds.

There was no claim of responsibility but the government has blamed previous attacks on Al Qaeda and Taliban militants intent on expanding their reach from bases close to the Afghan border.

President Pervez Musharraf blamed the same militants for the Dec. 27 gun and homicide attack that killed former Prime Minister Bhutto, a secular, female politician who had repeatedly pledged to battle Islamic extremism in this country of 160 million people.

Bhutto's supporters are alleging elements within the government may have had a role in her slaying and are demanding an independent, U.N. investigation, adding to pressures on Musharraf as he tries to stay in office, eight years after he took power in a military coup.

To allay critics, Musharraf last week invited British police to help probe the attack. The small team of Scotland Yard investigators was in Lahore on Thursday to examine evidence stored at forensic laboratories there, far from the scene of the bombing.

The attack in Lahore, which until Thursday has been spared the worst of the violence, shattered windows and set off tear gas shells carried by the police, preventing people getting close to the victims in the seconds after the blast, witnesses said.

"A man rammed into our ranks and soon there was a huge explosion," said police officer Syed Imtiaz Hussain who suffered wounds to his legs and groin. "I saw the bodies of other policemen burning. It was like hell."

Lahore police chief investigator Tasaddaq Hussain said the badly mutilated head of the homicide bomber had been recovered and would be reconstructed for identification purposes. His other body parts were being examined by forensic experts to extract his DNA, he said.

"The bomber seems to be a young man who was wearing a track suit. He had a thin beard," he said.

Police experts estimated the bomb contained up to 14 kilograms (30 pounds) of explosive.

The attack occurred about 15 minutes before lawyers were due to stage a protest in front of the colonial-era courthouse in Lahore — part of a nationwide movement against Musharraf for firing independent-minded Supreme Court judges who could have ended his rule.

Although it did not appear the lawyers were the target, the bombing could stifle further street protests and the willingness of Pakistanis to attend election rallies.

Shamim Akhtar, secretary of the Lahore Bar Association, said the lawyers' struggle would continue.

"Such cowardly acts cannot deter us from our struggle against authoritarian rule," he said.

Information Minister Nisar Memon said the bombing was an attempt to scare people from participating in the democratic process. He vowed the elections would go ahead and those responsible for the attack would be captured.

"We are after them. We will get them. They are on the run," he told Dawn News TV.

Late last month in Lahore, intelligence agents arrested a retired army major with alleged links to Al Qaeda in connection with a Nov. 1 bombing of an air force bus in the town of Sargodha that killed eight people and wounded 40. It was not clear if that arrest, disclosed just this week, was in any way linked to Thursday's attack.

Musharraf condemned the Lahore bombing and reiterated his resolve to fight terrorism, but Bhutto's widowed husband and political heir, Asif Ali Zardari, said it was further proof that the president had "miserably failed" to maintain law and order ahead of the elections.

The attack came on the eve of the Islamic month of Muharram, which is often marred by bombings and fighting between Pakistan's Sunni Muslims and its Shiite minority. Authorities have already boosted security at holy sites across the country.