Malcolm Turnbull's audacious double dissolution gamble looked to have backfired spectacularly on Saturday night, as voters walked away from the first-term Coalition government in droves, raising the chances of a hung parliament and turmoil in Coalition ranks.
Mr Turnbull's failure to secure a strong majority from voters represents a significant boost for Labor leader Bill Shorten, who campaigned strongly on the party's traditional strengths of health and education, ran a fierce scare campaign about Medicare being privatised and advanced an ambitious plan to cut negative gearing and capital gains tax concessions.
Australian voters used the   July 2 poll to deliver the rookie Prime Minister a stinging rebuke, with Liberal seats falling across the country, slashing the government's 90 seats in the 150-member lower house.
With swings across the country to Labor, the Greens and in particular a raft of independents led by Nick Xenophon and his new NXT party, the government's hopes of passing industrial relations legislation in a joint sitting are all but dead, while a significantly expanded Senate crossbench is also likely. 
Four hours after polls closed on Saturday night, Labor was on track to gain 13 seats, taking it to 68 seats in the lower house.
The Coalition looked set to secure 72 seats - short of the 76 seats needed for a majority. Five independents looked set to be elected, and the Liberal seats of Forde and Capricornia in Queensland, Lindsay in NSW and Cowan in WA were in doubt.
But the party had its nose in front, courtesy of the thumping majority secured by Tony Abbott in 2013.
Seasoned election watchers suggested the final count could take days with close contests likely to be decided by postal votes.
Tasmania emerged as the early surprise packet on the night, with three seats - Bass, Braddon and Lyons - set to return to the ALP, while Solomon in the Northern Territory also looked set to fall to Labor.
In NSW, another five seats - Barton, Dobell, Macarthur, Lindsay, Eden-Monaro and Macquarie - were trending towards Labor, and in Queensland another two Coalition seats - Herbert and Longman - were teetering.
In South Australia, Hindmarsh was likely to fall to Labor, and in Western Australia, the new seat of Burt also went to the ALP.
Also in South Australia, Nick Xenophon's NXT picked up the Liberal jewel of   Mayo, held by dumped junior minister Jamie Briggs.
Going against the trend, a possible break-out result could see the Labor-held seat of Chisholm - vacated by retiring former speaker Anna Burke - changing hands and falling to the Liberals.
In Victoria, the Melbourne seat of Batman, held by embattled Labor frontbencher David Feeney was on a knife-edge, with the Greens challenging strongly. And in country Victoria, the Nationals were poised to snatch Murray from their senior Coalition partners.
Voters expressed dissatisfaction with the Coalition's policy program, which had as its centrepiece a 10-year company tax cut plan but few other specific pledges that would affect voters in the next three years.
That plan allowed Mr Turnbull to pivot and run a campaign that focused heavily on the traditional Liberal strengths of economic management, but said less about national security.
But the claimed long-term benefits of those changes appear to have been outweighed by Mr Shorten's fierce campaign against the supposed privatisation of Medicare.
In addition, Mr Shorten's promise to scale back negative gearing and capital gains tax breaks, as well as spend more money on health and education, appeared to have struck a chord with middle Australia.
However, soon after polls closed, strategists from both sides were still predicting a narrow Coalition win as the most likely outcome.
In an early sign of the Coalition's concerns, Treasurer Scott Morrison told the ABC soon after polls closed that "first-term governments always have a swing against them". And as Liberal seats fell across the country, Mr Morrison - reflecting on Labor's "Mediscare" campaign - said: "I don't know what's more audacious - the size of the lie told or the boast made on the back of it about how it's been able to fool and trick people."
Foreign Minister Julie Bishop said: "Labor are boasting about the number of people they've deceived with this monstrous lie" about Medicare. Labor concocted a lie, ran with it. They weren't ever stopped by anyone within the Labor Party. Bill Shorten encouraged it."
Deputy Labor Leader Tanya Plibersek said it had been a "pretty good night for us".
"Whether it's good enough we won't know for some time. We've seen very strong results in NSW. A number of very strong swings towards us; seats that we will definitely pick up in NSW. In Tasmania it looks like we'll probably pick up more than one seat as well. Victoria looks like it's holding steady. Queensland I think will flow towards us."
The prospect of a very close result, in which the Coalition is reduced to a razor-thin majority, could see Mr Turnbull face severe internal pressure. A same-sex marriage plebiscite, promised for this year, threatens to embolden conservative MPs still bruised after the dumping of Mr Abbott last year.
Australia has not dumped a first-term government in 85 years, but with a record number of voters flirting with third-party independents, no side was confident of the outcome on Saturday night and a clutch of Senate and lower house crossbenchers could become kingmakers in the 45th Parliament.
The two leaders spent election day scrounging for every last vote, with Mr Turnbull and his wife, Lucy, voting in his electorate of Wentworth in the morning before giving the media pack the slip and heading out to the battleground western Sydney seats of Lindsay and Parramatta.
In a sign that both sides regarded Lindsay as still in play, Mr Shorten also visited, before flying home to Melbourne and a function in his electorate of Maribyrnong at the Moonee Valley race course.
Heading into the poll, Labor required a 4.1 per cent uniform swing to win 19 seats and claim the 76 seats in the lower house needed to form majority government.
The Coalition held 90 seats in the 44th Parliament, though that figure was reduced to a notional 88 seats after electoral redistributions, while Labor had held 55, which rose to 57 after the boundary changes.
An average of of public polls conducted in the last week of the campaign showed Labor's support had peaked and a late drift towards the Coalition had begun, with a uniform swing away from Mr Turnbull's government of 2.9 per cent - enough to see the Coalition reduced to about 82 seats and Labor claim 64, with four on the crossbench.
Western Australia also offered the potential for Labor gains, energised by the unpopularity of the Barnett government, with the new seat of Burt expected to land in the Labor column and the potential for Cowan and Hasluck to fall.
The final allocation of Senate preferences could take weeks to determine, with some predicting Mr Xenophon could win as many as four seats, and Tasmanian firebrand Jacqui Lambie tipped to win her seat. In Victoria, Derryn Hinch was in line to be elected.