Israel's military says five soldiers have been killed by Israeli tank fire in northern Gaza, in one of the deadliest incidents of its kind since the war against Hamas began in October.
An initial probe found that two tanks fired at a building in Jabalia refugee camp where the troops had gathered.
Troops went back into the area this week after previously pulling out, saying Hamas had regrouped there.
Tens of thousands of Palestinians have fled the fighting and bombardment.
Both the Israeli military and Hamas's military wing said on Wednesday that battles in Jabalia camp and the surrounding town of Jabalia were intensifying.
Battles also raged around the southern city of Rafah, from where nearly 600,000 people have fled since the start of an Israeli operation 10 days ago. More than a million displaced people had been taking refuge there.
The Israel Defense Forces (IDF) said five soldiers serving in the 202nd Battalion of the Paratroopers Brigade were killed in Jabalia camp on Wednesday evening "as a result of fire by our forces".
Two tanks in the area fired two shells at a building being used by the battalion's deputy commander, according to a statement.
"From the initial investigation... it appears that the tank fighters, from the ultra-Orthodox paratrooper company Hetz, identified a gun barrel coming out of one of the windows in the building, and directed each other to shoot at the building," it said.
Seven other soldiers were wounded by the tank fire, three of them seriously.
The deaths increased to 278 the number of Israeli soldiers killed since the start of the ground offensive in Gaza on 27 October.
Another 348 troops were among the 1,200 people killed in Hamas's unprecedented cross-border attack on southern Israel on 7 October, which triggered the war. Some were also taken back to Gaza as hostages.
More than 35,270 people have been killed in Gaza since then, according to the territory's Hamas-run health ministry.
According to the IDF's website, 44 of the soldiers killed in Gaza as of Wednesday - 15% of the total - died as a result of what it describes as "operational accidents".
Twenty-two of them were killed by "friendly fire", five died because of "firing irregularities", and 17 as a result of "accidents", including incidents involving weaponry and trampling.
On Thursday morning, official Palestinian news agency Wafa reported that there had been intense Israeli air strikes in the al-Hoja street area of Jabalia refugee camp, causing its "complete destruction". Five people were meanwhile wounded in a drone strike in the al-Faluja area, it added.
Hamas's military wing claimed on Thursday that it had fired an anti-tank missile at an Israeli troop carrier in the Block 2 area of Jabalia camp and targeted armoured bulldozers with explosive devices east of Jabalia town.
The IDF's Chief of Staff, Lt Gen Herzi Halevi, told troops in Gaza on Tuesday that Israeli forces were "striking widely and strongly" in Jabalia.
"We see there attempts [by Hamas] to hold on and rebuild, therefore we need to deal with this again, and prove that we will return each time," he added.
Wafa also cited medical sources as saying that more than 30 civilians, including 10 children, had been killed in Israeli air strikes on residential buildings in nearby Gaza City. Palestine Post photojournalist Mahmoud Jahjouh and several members of his family were reportedly among the dead.
The IDF scaled down operations in Jabalia, Gaza City and the rest of the north in January after declaring that it had "dismantled" Hamas's battalions there. But that left a power vacuum in which the group has been able to rebuild.
An estimated 300,000 people trapped in the devastated region are also experiencing a "full-blown famine" due to a lack of aid deliveries, according to the head of the World Food Programme.
In the south of Gaza on Thursday, fresh Israeli air strikes killed at least five people in southern and central Rafah, Wafa reported.
The IDF has ordered the evacuation of a number of neighbourhoods since 6 May, when it began what it called "precise operations" against Hamas in "specific areas of eastern Rafah and the Gazan side of the Rafah crossing".
Israel says it needs to send troops into the city because Hamas's last remaining battalions are based there. But the UN and Western powers say an all-out assault could lead to mass civilian casualties and a humanitarian catastrophe.