JERUSALEM — When the ceasefire agreement between Israel and Hamas was announced in January, Israelis and Palestinians burst into simultaneous celebrations, optimistic after 15 months of war.

Now, with the first phase of the deal over on Sunday and Israel introducing an entirely new proposal that Hamas has already rejected, concern is rising that the fighting that reduced the Gaza Strip to rubble, killed tens of thousands of Palestinians and threatened the lives of hostages could resume.

As the ceasefire teeters, both Hamas and Israel are pursuing two paths: one diplomatic and one military.

On the diplomatic front, Hamas is insisting on the implementation of the second phase of the original agreement, which calls for an end to the war, a full Israeli withdrawal from Gaza and the release of more hostages and prisoners.

Israel, though, has made a new proposal for a seven-week extension of the current ceasefire, during which Hamas would be required to release half the remaining living hostages as well as the remains of half the deceased ones. Israeli Prime Minister Benjamin Netanyahu on Sunday attributed the proposal to the work of President Donald Trump’s Middle East envoy, Steve Witkoff.

For weeks, Israel has been sending signals that it wasn’t interested in moving forward with the second phase of the agreement. Although the two sides agreed to the second phase in principle, they never worked out the details and have staked out irreconcilable visions.

Netanyahu has said repeatedly that Hamas’ government and military wing must be dismantled, a position shared by his right-wing coalition partners in the government. Hamas has suggested it was willing to give up civilian governance of Gaza but has firmly rejected dissolving its military wing, a critical source of its power in the enclave.

The new proposal, as described Sunday by Netanyahu, appears to be an attempt to replace the ceasefire deal with terms that would enable Israel to bring home dozens of hostages and remains of hostages without committing to the end of the war.

But the suggestion, analysts said, may be an effort to shake up the ceasefire talks in a way that breaks the deadlock between Israel and Hamas, at least temporarily.

In the first phase of the three-stage deal agreed to in January, Hamas released 25 Israeli hostages and handed over the bodies of eight others in exchange for more than 1,500 Palestinians jailed by Israel. But without further planned exchanges of hostages and prisoners, Israel will have fewer incentives to keep the truce going.

On Sunday, Hamas dismissed the new proposal as “a blatant attempt to renege on the agreement and evade negotiations for its second phase.”

Hamas considers the idea of immediately giving up half of the hostages a nonstarter, but it could consider exchanging a small number of hostages or bodies for Palestinian prisoners, even without a commitment to the end of the war, analysts said. The hostages represent Hamas’ most powerful leverage, and every time it trades an Israeli captive for Palestinian prisoners, its negotiating hand is weakened.