The Palestinian group Hamas which controls Gaza has reached a deal to end its decade-long rift with the Fatah faction which runs the Palestinian Authority from the West Bank.

The two parties had entered into talks brokered by the Egyptian Intelligence Directorate in Cairo on Tuesday.  Hamas last month had already signaled willingness to cede authority in Gaza to the Palestinian President Mahmoud Abbas' Fatah-backed government.

"Fatah and Hamas reached an agreement at dawn today upon a generous Egyptian sponsorship," read the statement from Hamas leader Hamas chief Ismail Haniyeh.

Fatah spokesman Osama Qawasmeh said, "We want to extend the rule of law to Gaza as in the West Bank."

The Western-backed Fatah faction lost control of Gaza in fighting in 2007.  Since then, Hamas - which is considered a terrorist organization in Israel and much of the West - got into three wars with Israel in which much of Gaza's infrastructure was destroyed.