- Coalition deal announced one hour before the deadline
- Deal with Naftali Bennett leaves Netanyahu in command of 61 Knesset votes
- Netanyahu says he hopes to expand the alliance
Israeli Prime Minister Benjamin Netanyahu held on to his job, announcing that he had hammered together a new coalition government just ahead of a midnight legal deadline.
But with a knife-edge majority of just one seat in the 120-member parliament expectations were that he would have to expand the ruling alliance beyond his natural religious and rightist partners or battle for survival at every vote.
"I am leaving here to call the president and the speaker of the parliament to inform them that I have been able to build a government," he said in remarks at the Knesset after marathon talks with Jewish Home leader Naftali Bennett on Wednesday.
"We need to launch it next week and we shall do so," he added.
President Reuven Rivlin's office said he had sent a written note followed up with a phone call.
"I am honoured to inform you that I have been successful in forming a government, which I will request is brought before the Knesset for its approval as soon as possible," Rivlin's office quoted the note as saying.
"The negotiations are over," Bennett said on his official Twitter account, adding, "Now we get to work."
The news came just over an hour ahead of a legal deadline at midnight (2100 GMT) after which the task of forming a government would have been given to another party leader - most likely Isaac Herzog, head of the centre-left Zionist Union, which won 24 seats in the March 17 election, behind 30 for Netanyahu's right-wing Likud.
The deal with Bennett leaves Netanyahu in command of 61 Knesset votes, bought at the cost of major concessions to his partners.
Analysts say he will be at the mercy of rebels, caprice, or even a bad cold the first time the coalition faces a crucial vote.
He would then be forced to expand the ruling alliance beyond his natural religious and rightist partners and turn reluctantly to the Zionist Union, which has so far said it will sit in opposition.
"Netanyahu is left with an unmanageable situation," said political scientist Emmanuel Navon, of Tel Aviv University.
"The first thing he'll do tomorrow ... is take his phone and start working on a coalition with [the Zionist Union]," he told AFP news agency.
Netanyahu, "is a general without soldiers", the Maariv daily wrote.
Netanyahu himself said he hoped to expand the alliance, without elaborating.
"I have said that 61 is a good number and 61-plus is better still, but it starts at 61," he said in his Knesset remarks.
For the time being his right-religious government is expected to continue his robust foreign policy - marked by virulent attacks on Iran - and to maintain a hard line on the issue of concessions to the Palestinians.