QALQILYA, West Bank - Forces loyal to the Palestinian Authority's Fatah leader stormed a Hamas hideout in the West Bank and set off a gun battle that left six dead yesterday, the worst violence since the factions fought a pitched battle over Gaza two years ago.

Extremists lobbed grenades and fired automatic weapons to push back the raid in a two-story building in Qalqilya, a West Bank town known for its strong Hamas presence. That drew dozens of forces allied with the more moderate Palestinian Authority President Mahmoud Abbas to the hideout.

When it was over, pools of blood, tear-gas canisters, and hundreds of spent shell casings littered the floor. Walls were partly burned down during the battle.

Qalqilya, which elected a Hamas mayor in 2005, was tense yesterday. Women gathered near the scene heaped insults on police officers, and scattered gunfire was heard.

The two factions have made intermittent attempts to reconcile since Hamas seized Gaza in 2007, leaving Fatah in control of only the West Bank. But yesterday's bloodshed showed just how little progress has been made.

The split has complicated Mideast peace efforts because the Palestinians cannot negotiate with Israel in a single voice and because Hamas refuses to recognize the Jewish state.

Last week, Abbas met at the White House with President Obama and renewed a pledge to crack down on extremists and honor other commitments under the road map. Abbas aide Nabil Abu Rdeneh said that going after the fighters was key to one day setting up a Palestinian state.

"To build our country and our state," he said, "we need to have one authority, one gun, one law."

Since Hamas' Gaza takeover, Abbas' security forces have detained hundreds of Hamas supporters in the West Bank and closed the group's institutions and charities.

Among those killed in the raid were two top Hamas figures who had been on the run from Israel for years. An unarmed Hamas supporter and three Palestinian police officers linked to Abbas' forces also died.

The Qalqilya clash began late Saturday when Palestinian troops surrounded a hideout of Mohammed Samman, a leader of Hamas' military wing, and his assistant, Mohammed Yassin. Both had been on Israel's wanted list for six years, Palestinian security officials said.

Initially, about two dozen officers stormed the house, breaking down the door, said a police officer who participated in the raid. He spoke on condition of anonymity because he was not authorized to speak to reporters. The Hamas men lobbed a grenade and opened automatic fire, killing three officers and wounding two critically, he said. Other officers fled, then brought in reinforcements.

The ensuing battle lasted until midmorning yesterday. Police said they found bombs, suicide belts, and bullets in the house. Security officials seized the bodies of the Hamas men, fearing a public burial would turn into protests against the Palestinian Authority.