Israel withdrew ground forces from the Gaza Strip on Tuesday and started a 72-hour ceasefire with Hamas mediated by Egypt as a first step towards negotiations on a more enduring end to the month-old war.
Minutes before the truce began at 8 a.m. (0500 GMT), Hamas launched a salvo of rockets, calling them revenge for Israel's "massacres". Israel's anti-missile system shot down one rocket over Jerusalem, police said. Another hit a house in a town near Bethlehem in the occupied West Bank. There were no casualties.
Israeli armour and infantry left Gaza ahead of the truce, with a military spokesman saying their main goal of destroying cross-border infiltration tunnels dug by Islamist militants had been completed. "Mission accomplished," the military tweeted.
Troops and tanks will be "redeployed in defensive positions outside the Gaza Strip and we will maintain those defensive positions", spokesman Lieutenant-Colonel Peter Lerner said, reflecting Israeli readiness to resume fighting if attacked.
Sami Abu Zuhri, a spokesman for the Islamist Hamas faction that rules Gaza, said Israel's offensive in the densely populated, coastal enclave was a "100 percent failure".
Israel sent officials to join talks in Cairo to cement a longer-term deal during the course of the truce. Hamas and Islamic Jihad also dispatched representatives from Gaza.
Israeli Prime Minister Benjamin Netanyahu convened his decision-making security cabinet to discuss the aftermath of the fighting, officials said.
In Gaza, where some half-million people have been displaced by a month of bloodshed, some residents, carrying mattresses and with children in tow, left U.N. shelters to trek back to neighbourhoods where whole blocks have been destroyed by Israeli shelling and the smell of decomposing bodies fills the air.
Sitting on a pile of debris on the edge of the northern town of Beit Lahiya, Zuhair Hjaila, a 33-year-old father of four, said he had lost his house and his supermarket.
"This is complete destruction," he said. "I never thought I would come back to find an earthquake zone."
Visiting International Red Cross President Peter Maurer, responding to local criticism that his organisation was late in helping some victims, said "we were insufficiently able to bridge the gap between our willingness to protect them and our ability to do so".
The head of Israel's southern command reassured residents who had fled southern Israeli towns when fighting erupted that it was safe to return home, though some remained unconvinced the threat of attack tunnels and rockets from Gaza had been wiped out.