Israeli Prime Minister Benjamin Netanyahu has managed to reach an agreement over the shape of his new government after resolving an 11th-hour crisis with a key centrist partner, media reports said on Wednesday.
The last-minute deal means Israel's new coalition government is likely to be sworn in just days before a top-level visit by US President Barack Obama.
Netanyahu has been locked in intensive coalition talks ahead of a looming March 16 deadline to announce the shape of his new government which must have a working majority of at least 61 within the 120-seat Knesset, or parliament.
Although the outline of coalition emerged earlier this week, a dispute over which party would take the prestigious education portfolio had on Wednesday threatened to derail the deal.
The breakthrough came after Netanyahu agreed that the new centrist Yesh Atid party could take the education portfolio, while the interior ministry would go to his rightwing Likud, Israel's main television and radio stations reported.
The leaders of the main parties were to meet later Wednesday to thrash out the wording of the agreement which will see Likud-Beitenu, which has 31 seats and is headed by Netanyahu and ex-foreign minister Avigdor Lieberman, form a government alongside Yair Lapid's Yesh Atid (19 seats) and Naftali Bennett's far-right Jewish Home party (12).
Until now, only one party has agreed to join a Netanyahu coalition -- the centrist HaTnuah of former foreign minister Tzipi Livni, which has six seats.
When the agreement is signed, it will give Netanyahu a majority of 68-70 seats, depending on whether or not the centre-right Kadima party, which has two seats, is also on board.
It was not immediately clear when the new government would be sworn in, with army radio suggesting it could be as early as Thursday while public radio said it would not happen until Monday, just two days before Obama arrives on March 20.
The Israeli parliament does not meet on Fridays, Saturdays or Sundays out of respect for the respective Muslim, Jewish and Christian days of rest.
Earlier, Netanyahu had threatened to turn to the ultra-Orthodox parties to form a coalition if Lapid refused to back down from his "exaggerated demands."
Lapid, who is widely expected to be a senior partner in the new government, has so far managed to convince Netanyahu to agree to a slimline cabinet of 20 ministers, down from 28, and to form a coalition without the ultra-Orthodox.
But the two locked horns over the education and interior portfolios.
"If, in the next hours there will not be a breakthrough in the negotiations with Lapid and he doesn't back down from his exaggerated demands, the prime minister will begin swift talks with the ultra-Orthodox parties," a Likud source said.
The threat was rejected out of hand by Yesh Atid.
"The coalition crisis that we are currently witnessing is not about which portfolio is given to which party. This is a struggle for the moulding of the future image of Israeli society," a senior party source said.
"Yair Lapid refuses to deviate from his principles and from his promises to the Israeli voter, even if that means that Yesh Atid will have to sit in the opposition."
Late on Tuesday, Netanyahu reportedly met Jewish Home's Bennett who has so far stuck closely to Lapid, with the two agreeing that neither party would enter the coalition without the other.
As news of Netanyahu's threat emerged, Bennett was quick to shoot it down.
"My friends from Likud. Forget it. It won't work like this," he wrote on Facebook. "There are differences, we must talk and compromise. All of us. Until there is a new government."
The night before issuing his ultimatum, Netanyahu had also reportedly met with a member of Shas, one of the two ultra-Orthodox parties which collectively count for 18 seats.