The Liberal party has retained Ryde, the last seat to be decided at the New South Wales election, the ABC's election analyst, Antony Green, has confirmed.
The final result leaves Labor holding 45 seats, the Coalition with 36, the Greens on three, while independent candidates hold nine seats.
Green confirmed the Ryde result this morning, two weeks after the election was held on March 25, with the Liberal party's candidate, Jordan Lane, ahead by around 50 votes.
Counting since the election has seen the two candidates, Lane and the Labor party's Lyndal Howison, on a knife-edge, with only a few hundred votes between them.
In a statement, Mr Lane thanked his supporters in Ryde and wished the other candidates "all the best".
"I love Ryde, and will continue to fight every day to deliver on our positive vision for our community and its future," he said.
"I look forward to working hard for everyone in Ryde, no matter who they voted for.
"It's also appropriate to acknowledge all of the other candidates, and I wish them and their families all the best for the Easter break."
Earlier, Ms Howison acknowledged it was "not looking good" as vote counting saw the lead she had gained on polling day reduced by pre-poll and postal votes.
"As I’ve said, it has been a great privilege to be the Labor candidate and I’ve loved meeting so many wonderful Ryde residents. Thank you," she said in a social media post last Saturday.
The ABC results show a swing of 8.6 per cent to Labor in Ryde, previously held by retired MP Victor Dominello, with a margin of 8.9 per cent.
A spokesperson for the Labor party said the party would consider its options after the Easter break regarding a recount of the vote.
"Given the closeness of the count, in these circumstances it's not unusual to request a recount," the spokesperson said in a statement.
"We will consider our options over the coming days."
Premier Chris Minns will head a minority government after the result left his party two seats short of the number needed to form a majority.
Mr Minns and seven members of his ministry were sworn in by Governor Margaret Beazley at Government House on March 28.
The ABC understands that the government will not make any deals to pass legislation, but will consider each bill on its merits and vote accordingly.
Key independents Alex Greenwich, Joe McGirr and Greg Piper issued a statement shortly after the election offering "confidence and supply" to the government.
Earlier projections had Labor winning the necessary 47 seats to form a majority government.