Four Israeli soldiers were killed today in the northern Gaza Strip when their tank rumbled over a bomb and exploded, igniting ammunition and fuel that turned the inside of the armored vehicle into a fiery death trap for its crew, according to Israeli military officials.

Blasts from exploding tank shells, machine gun bullets and fuel ripped through the tank's cavity, tore off part of its turret and flung one soldier's body out of the vehicle. The tank burned for nearly four hours before rescue workers could extinguish the blaze, Palestinian witnesses and military officials said.

"I heard a huge explosion," said Mohammed Abu Halima, an 18-year-old college student who lives near the site of the blast. "Fire came from the middle of the tank, and I saw a soldier flying in the air with the fire."

"All four soldiers were killed immediately," said Maj. Gen. Doron Almog, who heads the Israeli Southern Command, which includes the Gaza Strip. "We dragged the tank away with the dead inside."

A military spokesman confirmed that one soldier was thrown out of the tank by the force of the explosions.

The blast destroyed the Magach 7 tank as it crawled atop a sand berm separating this sprawling Palestinian town from the desert strip that surrounds the nearby Jewish settlement of Dugit. It was the fourth Israeli tank to be destroyed in the Gaza Strip in the past year and the first time an entire crew has been killed, Almog said. Seven soldiers have died in three previous attacks on the larger and more heavily armored Merkava tanks.

The military wing of the Islamic Resistance Movement, known as Hamas, claimed responsibility for the attack. A statement released by the organization shortly after the explosion said the assault was retribution for the deaths of two Palestinian men who were shot by Israeli forces on Thursday near the wall surrounding Dugit.

"They [the Israelis] have the military power," said Ismail Haniya, a Hamas political leader, in an interview in nearby Gaza City. He said the attack on the tank was intended to show that "they can't break our will or destroy the resistance."

At 8:21 a.m. today, the four men inside the Israeli tank were following the tracks of an armored bulldozer designed to take the brunt of mines and explosives when a 220-pound bomb hidden in the sand detonated beneath the tank's rear left side, Almog said at a press briefing in Tel Aviv. He said the device may have been hidden in the berm "a long time."

Israeli armored vehicles routinely chug up the berm to observe activity on the Palestinian side, Israeli military officials and Palestinian witnesses said.

The rescue operation was hampered by the intense heat radiating from the tank, as well as a driving rain and thick mud, Almog said.

Although Almog said a 220-pound explosive "will penetrate any kind of armor," he said the military will investigate whether the Magach tanks need additional improvements to protect the soldiers inside.

As soon as the tank was lifted off the berm by a crane and driven away, Israeli armored bulldozers began demolishing two Palestinian apartment houses and several vegetable greenhouses about 200 yards from where the tank exploded.

An army spokesman said the houses were demolished because Israeli forces will continue to conduct operations in the area.

"After this incident we recognized it will be harder to do those activities," he said. "That's why we had to take down these buildings."

Palestinian residents said soldiers fired into their neighborhood during the rescue operation and set up a sniper post on the top floor of one house. An Israeli soldier fired on journalists interviewing a group of neighbors two blocks from the housing demolitions. No one was injured.

It took military officials hours to notify the soldiers' families of their deaths because many observant Jews do not answer their telephones on Saturday, the Sabbath, military officials said. As of late tonight, a military spokesman said the names of the soldiers could not be released because all of their families still had not been reached.

Israeli soldiers survey damage to a tank that burned for nearly four hours after it drove over a bomb in the Gaza Strip.