In its bloody assault on Israel, Hamas was aiming to break a stalemate in Gaza, analysts say, but with its neighbour now determined to eradicate the Islamist group, it may have made a fatal mistake.
Responsible for governing the coastal enclave since its violent takeover in 2007, Hamas had come under pressure from the Palestinian public for the dire humanitarian conditions in Gaza, said George Giacaman, a professor at Birzeit University in the occupied West Bank.
"The people's anger towards Israel had become anger towards the government and therefore towards Hamas," Giacaman told AFP.
Hamas was created in 1987, amid the first Palestinian intifada (uprising) against Israel's occupation, by a group of militants claiming to be from the Muslim Brotherhood.
By the 1990s, Hamas, Arabic acronym for the Islamic Resistance Movement, had become the spearhead of the armed struggle against Israel, with Yasser Arafat's PLO turning away from violence and towards the peace process.
Hamas developed a vast social welfare network alongside charitable works, most notably schools, which help explain an influence and popularity that has surged at the expense of the Palestinian Authority, considered by many Palestinians to be corrupt and complicit with Israel.
The current head of Hamas, Ismail Haniyeh, lives between Turkey and Qatar, although the group is directed in Gaza by Yahya Sinwar, seen as a hardliner within the movement.
Hamas has a separate armed wing, the Ezzedine al-Qassam Brigades, which is led by the elusive Mohammed Deif, Israel's public enemy number and a man they have tried to assassinate on multiple occasions.
Angered that it was blocked from exercising real power after winning a parliamentary election in 2006, Hamas - considered a terrorist group by the European Union and the United States - ousted loyalists of Palestinian president Mahmud Abbas from the Gaza Strip in 2007 to take undisputed control of the territory.
Following its takeover, Israel, which withdrew troops and settlers from Gaza in 2005, imposed a strict blockade on the territory and its now 2.4 million people, which the United Nations has described as "collective punishment".
Political instability
Despite multiple Israeli offensives aimed at ending rocket launches from Gaza, Hamas has retained control of the enclave, most of whose population are the descendants of refugees who were driven from their lands during the creation of the State of Israel in 1948.
In 2018, Hamas and Israel agreed a long-term truce intended to stabilise the Gaza Strip, beset by poverty and unemployment, following mediation by Egypt, Qatar and the United Nations.
Although Hamas engaged in a new round of hostilities with Israel in 2021, it stayed out of May 2023 clashes between Israel and Islamic Jihad, the other main Islamist armed group in Gaza.
That stance had provided ammunition to Hamas's rivals, who accused it of pursuing its own interests in observing a ceasefire with Israel, in exchange for, among other things, an easing of the economic blockade.
However, political instability in Israel - which has held five elections in three and half years and since late last year has been governed by a coalition including far-right parties wholly opposed to any concessions to the Palestinians - destabilised that arrangement.
The powerlessness of Hamas when confronted with the deteriorating living conditions in Gaza is one reason why it launched its brutal offensive on October 7, in which more than 1,200 civilians, soldiers and foreigners were killed in Israel and dozens taken hostage, Giacaman said.
"Life in Gaza had become unbearable. Water and electricity are lacking and unemployment is very high. Gaza is a giant prison that depends on Israel for its food and for this the crossing points must remain open," he told AFP.
'A large-scale response'
The timing of the operation, dubbed "Al-Aqsa Flood" by Hamas, is also linked to "the escalation of provocations by the Israeli extreme right at the Al-Aqsa Mosque," including the increasing number of Jewish worshippers visiting the mosque compound in Jerusalem's Old City, said Giacaman.
"Hamas regarded what is happening at Al-Aqsa, a symbol of both religious and national significance for Palestinians that should never be underestimated, as an opportunity to launch its attack," he said.
Israel's reprisals against Gaza have killed more than 1,300 people, the majority of them civilians, according to health officials.
Netanyahu said on Wednesday that "every member of Hamas is a dead man", adding that Israel would "crush and destroy" the movement.
Israel has in the past killed multiple Hamas chiefs -- in March 2004, it assassinated the Islamist group's spiritual leader, Sheikh Ahmad Yassin and, just a month later, his successor Abdel Aziz al-Rantisi -- but without significantly weakening it.
"It would be inconceivable for them (Hamas) not to expect a major Israeli response, one that could further destroy Gaza, exact a terrible toll on its long-suffering inhabitants and possibly spell the end of Hamas governance in the enclave," said Brussels-based think tank, the International Crisis Group.