By Tom Westbrook, Melanie Burton and Jonathan Barrett
SYDNEY/MELBOURNE (Reuters) - Australia's Liberal-led conservative government was headed for a remarkable win at the national election early on Sunday after uncovering a narrow path to victory that twisted through urban fringes and rural townships.
The results upended pre-election polls which predicted a Labor victory, though it is unclear whether the Scott Morrison-led coalition can govern with an outright majority or will need to negotiate support from independents.
The final result may not be known for some time.
"I have always believed in miracles," Morrison told cheering supporters at Sydney's Wentworth Hotel, where the government holds its official election night function.
"Tonight is not about me or it's not about even the Liberal party. Tonight is about every single Australian who depends on their government to put them first."
The conservative government has won or is leading in 72 seats in its quest for a 76-seat majority, according to the Australian Electoral Commission, with just over two-thirds of votes counted.
Several seats are still too close to call and the final result is complicated by a large number of early votes that have delayed counting.
Morrison's coalition defied expectations by holding onto a string of outer suburban seats in areas where demographics closest resemble America's Rust Belt, blocking Labor's path to victory.
This included a devastating result in the coal-rich state of Queensland, which backed the Pentecostal church-going prime minister by defying expectations and delivering several marginal seats to his government.
U.S. President Donald Trump spoke with Morrison and congratulated him, the White House said. "The two leaders reaffirmed the critical importance of the long-standing alliance and friendship between the United States and Australia, and they pledged to continue their close cooperation on shared priorities," it said.
Voters on Saturday cast their ballots for Morrison's message of support to aspirational voters and turned their back on Labor leader Bill Shorten's reforms.
"I know that you're all hurting and I am too," Shorten told supporters at the party's Melbourne election night function.
"And without wanting to hold out any false hope, while there are still millions of votes to count and important seats yet to be finalised, it is obvious that Labor will not be able to form the next government."
Shorten said he would step down as the party's leader.
Labor, a party with deep ties to the union movement, had promised to abolish several property and share investment tax concessions primarily aimed at the wealthy.
Both major parties suffered a decline in their primary vote, according to AEC data, which was caused in part by a well-funded campaign by Clive Palmer's populist United Australia Party.
The election sparked several high-profile local battles, including attempts to remove Peter Dutton, a senior lawmaker who has championed Australia's controversial policy of detaining asylum seekers in offshore centres.
Although Dutton has retained his Queensland seat, former conservative prime minister Tony Abbott lost his Sydney beaches seat of Warringah to high-profile independent Zali Steggall.
"So, of course, it's disappointing for us here in Warringah, but what matters is what's best for the country," Abbott told supporters in a concession speech.
"And what's best for the country is not so much who wins or loses Warringah, but who forms, or does not form, a government in Canberra."
There were also 40 of 76 Senate spots contested in the election, the outcome of which will determine how difficult it will be for the next government to enact policy.
(Reporting by Tom Westbrook, Melanie Burton and Jonathan Barrett; additional reporting by Swati Pandey, John Mair, Steve Holland and Timothy Gardner ; writing by Jonathan Barrett; Editing by Ros Russell and Cynthia Osterman)