|Previous attempts to form a unity government have ended in fighting and bloodshed [GALLO/GETTY]
Fatah and Hamas have inked a reconciliation pact in Cairo, Egypt, aimed at ending their four-year rift. But it is not the first time the two groups have tried to put their differences aside.
Below is a timeline of key events in the conflict between them.
Jan 25, 2006: Hamas defeats Mahmoud Abbas' long-dominant Fatah party in parliamentary polls.
March: Hamas government sworn in, headed by Ismail Haniyeh, after Fatah refuses to join. Western backers including the US and European Union say Hamas is a "terrorist" organisation and refuse to recognise group as the legitimate winner.
September: Abbas and Haniyeh announce agreement to form a unity administration, but talks flounder over what the new cabinet's stance will be towards Israel. Abbas's Fatah movement supports a Palestinian state alongside Israel, while Hamas rejects Israel's right to exist. Their disagreements lead to violence on the streets of Gaza.
October: A number of mediation conferences are held. Egypt and Qatar send their foreign ministers to meet with both sides. Other Palestinian groups such as the Islamic Jihad and the Popular Front for the Liberation of Palestine mediate between the two sides to stop the clashes.
November: Following talks between Hamas and Fatah, both sides agree to form a unity government.
December: Abbas calls for new elections as a solution to the ongoing crisis.
February 2007: Fighting between Hamas and Fatah factions intensifies in Gaza, with Hamas overrunning compounds used by Abbas's security forces. The two sides then agree on a deal in Mecca, in the hope that Western powers will lift crippling sanctions imposed on the Hamas-led government. Haniyeh and his cabinet resign, but he is re-appointed by Abbas and begins the process of forming a new Palestinian unity government.
March: The Palestinian unity government takes office, but Hamas says it will not halt rocket fire against Israel, as proposed by Abbas, after the Jewish state vows to press ahead with its attacks on Gaza.
June: Battle of Gaza begins, resulting in Hamas taking control of the Gaza Strip from Fatah, who stay in control of the occupied West Bank. At least 100 people are killed in the heavy fighting. Abbas dismisses the Palestinian government and declares a state of emergency.
November: George Bush, the then US president, hosts peace talks between Palestinians and Israelis at Annapolis, Maryland, while Hamas still holds control over Gaza.
January 2008: Israel steps up military actions on Gaza and Hamas, killing seven Palestinians. Ehut Olmert, the then Israeli PM, vows to respond to continuing rocket attacks from Gaza. Israel continues incursions into Gaza, leaving Palestinians in a humanitarian crisis without fuel, power, food and water.
December 2008: Israel launches Operation Cast Lead, a full scale invasion of the Gaza Strip in response to rocket attacks by Palestinian armed groups. Some 1,400 Palestinians are killed, many of them civilians. After 22 days of fighting, Israel and Hamas each declare separate unilateral ceasefires.
January 2009: Abbas' term as president ends, but vows to stay in power until parliamentary and presidential elections can be held simultaneously.
February 2009: Egypt pushes Fatah and Hamas to hold reconciliation talks to create a unity government that would allow for simultaneous presidential and parliamentary elections.
April 2009: The two groups suspend reconciliation talks for three weeks after failing to agree on a unity government.
September 2010: Round of direct negotiations between the Israeli and Palestinian leadership begins. The talks collapse in the same month after Israel refuses to extend the freeze on settlement construction in the West Bank.
May 3, 2011: Unity deal between Fatah and Hamas signed in attempt to end feud between the two groups, which remain divided between the Gaza Strip and occupied West Bank. The deal involves members of the Palestinian Liberation Organisation (PLO) and Islamic Jihad, Popular Resistance Committee and Hamas.
May 4, 2011: Fatah and Hamas leaders, Abbas and Khaled Meshaal, gather in Cairo to mark the reconciliation agreement.