Scott Morrison appears set to return to power after voters in Queensland, NSW and Tasmania rallied behind the Liberal-National coalition.
However, former prime minister Tony Abbott has become the biggest casualty of the day losing his seat to independent Zali Steggall.
At 9.45pm, it appeared the coalition was holding 73 seats to Labor's 65, with eight seats in doubt.
A party needs 76 seats to have a majority in the lower house.
The crossbench is set to include at least independents Andrew Wilkie and Ms Steggall, Katter's Australian Party leader Bob Katter, the Centre Alliance's Rebekha Sharkie and the Greens' Adam Bandt.
The Liberals benefited from a strong flow of preferences from Clive Palmer's United Australia Party and Pauline Hanson's One Nation, which together gained almost 6.5 per cent of the national primary vote.
Key Liberal figures pointed to Mr Abbott's opposition to ambitious action on climate change, and role in the downfall of Malcolm Turnbull, as factors in his falling out of favour with local moderate voters.
Former Liberal deputy leader Julie Bishop described the loss of Warringah as an "inevitable outcome" but was growing in confidence Mr Morrison would stay in power.
She said Mr Morrison's presidential-style campaign had been successful.
"If Scott Morrison pulls this off he will be forever immortalised in the history of the Liberal Party - he will be confirmed enduring fame if he is able to find that goat track back," she told Nine Network.
"Actually, it's a single lane highway now."
Mr Abbott told supporters at a rally there was "every chance the Liberal-National coalition has won this election.
"It is a stupendous result," Mr Abbott said.
"Scott Morrison will quite rightly enter the Liberal pantheon forever."
Former prime minister John Howard said Mr Morrison "deserves the overwhelming gratitude of the Liberals all around the country."
It appeared the Liberals had gained the seats of Bass and Braddon in Tasmania, Herbert and Longman in Queensland, and Lindsay in NSW.
The Liberals were also ahead of Labor in the NSW seat of Macquarie.
Labor looked set to take Chisholm and Gilmore, and was ahead of the Liberals in the South Australian seat of Boothby.
Western Australia was expected to rally for Labor but the swing did not eventuate.
"These are not the numbers the Labor Party wanted to see ... Labor was going into this election expecting to form government early tonight," former Labor senator Sam Dastyari said.
Labor senator Penny Wong said Queensland had been tough for federal Labor for a "fair while".
She laid part of the blame on Queensland-based billionaire Mr Palmer, who spent an estimated $60 million on advertising for his United Australia Party.
"Mr Palmer's relentless advertising, which essentially set a pox on everybody, is much more difficult for a party like ours," Senator Wong said.
The Nationals appear to have held all of their seats.
Published opinion polls had been in Labor's favour.
Do you have a story tip? Email: email@example.com.