A joint operation by the Israel Defence Force (IDF), Israel's domestic Shin Bet security service and the Special Police Unit in Rafah freed Fernando Simon Marman, 60, and Louis Hare, 70, the Israeli military said.
The two men, who were kidnapped by Hamas from Kibbutz Nir Yitzhak on Oct. 7, were in good condition and taken to the Tel Hashomer Medical Complex, the military said.
"It was a very complex operation," Israeli military spokesman Lt Col. Richard Hecht said. "We’ve been working a long time on this operation. We were waiting for the right conditions."
The hostages were being held on the second floor of a building that was breached with an explosive charge during the raid, which saw heavy exchanges of gunfire with surrounding buildings, Hecht said.
At the same time, an air strike was carried out to allow the forces to be extracted, he said.
The air strikes caused widespread panic in Rafah as many people were asleep when the strikes started, said residents contacted by Reuters using a chat app. Some feared Israel had begun its ground offensive into Rafah.
Israeli planes, tanks and ships took part in the strikes, with two mosques and several houses hit, according to residents.
The Israeli military said on Monday it had conducted a "series of strikes" on southern Gaza that have now "concluded," without providing further details.
Before previous assaults on Gaza cities, Israel's military has ordered civilians to leave without preparing any specific evacuation plan.
U.S. President Joe Biden told Prime Minister Benjamin Netanyahu on Sunday that Israel should not launch a military operation in Rafah without a credible plan to ensure the safety of the roughly 1 million people sheltering there, the White House said.
Aid agencies say an assault on Rafah would be catastrophic. It is the last relatively safe place in an enclave devastated by Israel's military offensive.
Biden and Netanyahu spoke for about 45 minutes, days after the U.S. leader said Israel's military response in the Gaza Strip had been "over the top" and expressed grave concern over the rising civilian death toll in the Palestinian enclave.
Netanyahu's office has said that it had ordered the military to develop a plan to evacuate Rafah and destroy four Hamas battalions it says are deployed there.
Hamas militants killed 1,200 people in southern Israel and abducted at least 250 in their Oct. 7 incursion, according to Israeli tallies. Israel has responded with a military assault on the Gaza Strip that has killed more than 28,000 Palestinians, according to the Hamas-run health ministry.
Netanyahu said in an interview aired on Sunday that "enough" of the 132 remaining Israeli hostages held in Gaza were alive to justify Israel's war in the region.
Hamas-run Aqsa Television on Sunday quoted a senior Hamas leader as saying any Israeli ground offensive in Rafah would "blow up" the hostage-exchange negotiations.
Egypt warned on Sunday of "dire consequences" of a potential Israeli military assault on Rafah, which lies near its border.
"Egypt called for the necessity of uniting all international and regional efforts to prevent the targeting of the Palestinian city of Rafah," its foreign ministry added in a statement.