AN Israeli strike on a school sheltering the displaced in the Gaza Strip killed at least 27 people on Thursday, Palestinian medical officials have said.

The Israeli military said it targeted militants hiding among civilians, without providing evidence.

Israel has continued to strike at what it says are militant targets across the Palestinian enclave even as attention has shifted to its war against Hezbollah in Lebanon and rising tensions with Iran.

READ MORE: Palestinian refugee to take Home Office to court in bid to bring family to Scotland

The military launched a large-scale air and ground operation against Hamas in northern Gaza earlier this week.

The Al-Aqsa Martyrs Hospital, where the bodies were brought, said the strike in the central town of Deir al-Balah killed 27 people, including a child and seven women.

It said several other people were wounded. The Israeli military said it carried out a precise strike targeting a militant command and control centre inside the school.

Israel has repeatedly attacked schools that were turned into shelters in Gaza, accusing militants of hiding out in them.

Witnesses who spoke to the Associated Press on condition of anonymity for security reasons said the strike occurred while school managers were meeting with representatives of an aid group in a room normally used by Hamas-run police who provide security.

They said there were no police in the room at the time.

The Hamas-run government operated a civilian police force numbering in the tens of thousands.

They largely vanished from the streets after the start of the war as Israel targeted them with airstrikes, but plainclothes Hamas security personnel still exert control over most areas.

Hamas has continued to launch attacks on Israeli forces and fire occasional rockets into Israel more than a year after its October 7 attack ignited the war.

READ MORE: Pro-Palestine activists smash windows and spray Glasgow building over 'Israel links'

Hamas-led militants stormed into Israel and rampaged through army bases and farming communities in that attack, killing some 1200 people, mostly civilians, and abducting around 250 others.

They are still holding around 100 captives, a third of whom are believed to be dead.

Israel’s offensive has killed over 42,000 Palestinians, according to local health authorities, who do not say how many were fighters but say women and children make up more than half of the fatalities.

The war has destroyed large areas of Gaza and displaced around 90% of its population of 2.3 million people, often multiple times.