Ashkelon, Israel (CNN) Israel and militant factions in Gaza appear to have reached a ceasefire after a violent weekend that saw the some of the worst fighting between the two sides since 2014, when full-blown war broke out.

At least 23 people were killed in Gaza, including two infants and two pregnant women, in the exchanges that began Friday, while four people were killed in Israel by rockets.

A spokesman for the Palestinian group Islamic Jihad told CNN that the agreement took effect at 4:30 a.m. local time in Gaza.

Israel rarely confirms or comments on the existence of any ceasefire. But Israeli authorities have lifted all restrictions on civilians in the Gaza periphery, which is likely a clear indication that Israel expect this latest round of fighting has ended.

Smoke is sen rising after an Israeli air raid on homes in Gaza City.

Israeli Prime Minister Benjamin Netanyahu had warned Sunday that "massive attacks against terrorist elements" would continue due to the rocket attacks coming from Gaza.

At his weekly Cabinet meeting Sunday morning, Netanyahu said "Hamas bears the responsibility not only for its own attacks and actions but also for the actions of Islamic Jihad, and it is paying a very heavy price for this."

Israeli Economy Minister Eli Cohen used similar language in discussing the conflict.

"The rules of the game have changed. We are preparing for a campaign that, by the end of it, Hamas and Islamic Jihad will beg for a ceasefire," Cohen said in a statement posted on social media.

"The heads of the snake in Gaza are already paying a price and they will continue to a heavy price for the unnecessary provocation and the harm to our citizens."

Hamas threatened a similar escalation if the fighting continued.

"We stress that the more atrocious the Israeli attacks on the Palestinian civilians are, the stronger the Palestinian response will be," Ismail Haniyeh, Hamas' leader in Gaza, said in a statement Sunday.

"If the Israeli occupation does not implement the ceasefire understandings, the battlefield will witness more escalation."

The violence marks the first serious escalation in hostilities since the Israeli election about a month ago. Included among the deceased in Gaza are eight members of the armed wing of Islamic Jihad -- the Quds Brigade -- a spokesman for the group said.

The weekend also saw the first use of a targeted killing by Israeli authorities in Gaza in years. Israeli aircraft struck the vehicle of Hamid Ahmed Abdul Khudri, according to the Israel Defense Forces (IDF), who they say was responsible for money transfers from Iran to militant groups like Islamic Jihad and Hamas, the two largest factions inside the Gaza Strip.

Palestinians inspect the remnants of the Abo Kamar building after airstrikes carried out by Israeli warplanes in Gaza City, Gaza, on Sunday

Clashes

The catalyst for the weekend of hostilities occurred Friday afternoon.

Two Palestinians were shot and killed by Israeli troops during weekly protests along the fence between Gaza and Israel Friday, according to Palestinian health officials.

Also during the demonstrations, a sniper in Gaza wounded two Israeli soldiers near the border. Israel responded by striking a Hamas military post, killing two members of Hamas' military wing.

Hamas and other factions inside Gaza vowed to hit back. On Saturday morning, militant factions fired a barrage of rockets into Israel.

The fighting escalated by the hour. Short-range rockets targeting the Gaza periphery gave way to more powerful rockets aimed at Beer Sheva and Ashdod, some of the largest cities in southern Israel. Islamic Jihad also fired an anti-tank missile at an Israeli civilian vehicle. Israel's attacks escalated as well, from hitting smaller military posts to larger multi-story buildings the IDF says were used as terror infrastructure by Hamas and Islamic Jihad.

By the time the sun rose Monday, Palestinian militants had fired about 690 rockets into Israel, according to the IDF, and Israel had conducted airstrikes on 350 targets.

Rockets are fired toward the Israeli areas from Gaza Strip Sunday.

Those killed in Israel include two men in their fifties, health officials said. In Gaza, two infants, a 12-year-old boy and two pregnant women were among the dead, per Gazan officials.

There is a dispute over the cause of the deaths of one of the infants and one of the pregnant women -- Gaza health officials say both died in an Israeli airstrike, while the Israeli military says they were killed when a militant rocket misfired on launch.

People inspect the damage at a house in the southern Israeli city of Beersheba on Sunday after it was hit in a rocket strike from Gaza.

Diplomatic attempts to bring an end to the fighting continued throughout the weekend, including "very intense" mediation efforts by Egypt and the United Nations, a source with direct knowledge of the negotiations told CNN.

UN Secretary-General Antonio Guterres' office condemned "in the strongest terms the launching of rockets from Gaza into Israel, particularly the targeting of civilian population centers" in a statement Sunday.