The Hamas-run health ministry in Gaza has said dozens of people were killed or injured in a blast at a refugee camp in the Rafah area.
The Israel Defense Forces (IDF) said it had carried out an air strike targeting a Hamas compound in the area. It says it is reviewing the incident.
Earlier in the day Hamas fired eight rockets from Rafah towards Tel Aviv, the first long-range attacks on the city since January.
Videos from the southern Gaza Strip show a large explosion and intense fires burning.
Hamas said an Israeli air strike had hit a camp for displaced Palestinians north-west of Rafah, away from recent military operations in a designated humanitarian safe zone.
It says women and children are among the dead.
The IDF said it had targeted Hamas militants in the area and said it was aware of reports the strike had ignited a fire which harmed civilians.
It was reviewing the incident but said it had used precision weapons against legitimate targets.
In a statement, the IDF said it had “eliminated” two senior Hamas figures – Yassin Rabia Rabia and Khaled Nagar Nagar – in a “precise” air strike “in north-west Rafah”.
The Hamas-run health ministry said 35 people had been killed and dozens injured in an Israeli strike.
A Palestinian Red Crescent Society spokesperson quoted by the Associated Press news agency said the death toll was likely to rise as search and rescue efforts continued in Rafah’s Tal al-Sultan neighbourhood about 2 km (1.2 miles) north-west of the city centre.
An eyewitness told Reuters news agency the whole neighbourhood in Tal Al-Sultan had been “burnt”.
Another witness, Fadi Dukhan, described sitting at the door of a house when he heard an explosion.
“Suddenly we heard the sound of a missile,” he told Reuters. “We ran and found the street covered in smoke. We did not see anything.”
Entering a house, he added, he did not find anyone inside but later found “a girl and a young man who had been cut into pieces”.
Earlier on Sunday air raid sirens sounded around Tel Aviv as central Israel came under attack by Hamas rockets, fired from close to Rafah.
The eight rockets were either intercepted by air defence systems or fell in fields.
Israel’s military offensive has continued in Rafah, despite the International Court of Justice ruling on Friday that it must halt.
The rocket barrage highlights the threat Hamas still poses to people across Israel, although there were no reports of injuries.
It also illustrates the challenges the Israeli army faces as it moves further into southern Gaza to oust Hamas from what it calls its “last major stronghold”.
The rocket attack came ahead of further ceasefire negotiations between Israel and Hamas, which are expected to resume next week.
The military wing of Hamas said it had acted in response to “the massacre of civilians”.
Israel began a long-anticipated offensive in Rafah about three weeks ago, vowing to destroy the remaining Hamas battalions there.
It says it believes Israeli hostages are also being held in the town.
The UN says more than 800,000 Palestinians have fled from Rafah since the offensive began.
About 1.5 million had been sheltering there from the fighting elsewhere in Gaza.
Israel’s military campaign in Gaza began after Hamas-led gunmen attacked Israel on 7 October, killing about 1,200 people and taking 252 others back to Gaza as hostages.
Nearly 36,000 Palestinians have been killed in the war since then, according to Gaza’s Hamas-run health ministry.