(AFP) -- "An agreement was reached today between Hamas and Fatah under Egyptian sponsorship," a statement from Hamas leader Ismail Haniya's office said, without giving further details.
Fayez Abu Eita, a Fatah spokesman and member of the party´s delegation in Cairo, told AFP details would be announced at a press conference later on Thursday.
The two sides had been meeting in the Egyptian capital since Tuesday, with the aim of ending a crippling decade-old split between the rival factions.
A party to the negotiations, who asked not to be identified, said the agreement would see forces of the West Bank-based Palestinian Authority, which is dominated by Fatah, take control of the Rafah border crossing between Gaza and Egypt.
He added that all Palestinian factions would begin wider negotiations on the formation of a national unity government in the coming two weeks.
Egypt has been keen to improve security in the Sinai Peninsula which borders Gaza and where [terrorist] rebels have fought a long-running insurgency.
Last month, Hamas agreed to cede civil power in Gaza to the Palestinian Authority but the fate of its vast military wing remains a significant issue for the two sides.
An Egyptian source close to the talks said intelligence chief Khaled Fawzi had followed the talks closely.
Hamas is blacklisted as a terrorist organisation by the United States and the European Union.
It has fought three wars with Israel since 2008 and the blockaded Gaza Strip has faced deteriorating humanitarian conditions.
(Photo: A Gazan flashes a victory sign behind a large Palestinian flag as he and others await the arrival of prime minister Rami Hamdallah on a visit that has raised hopes of an end to a decade-long split, AFP)