Recep Tayyip Erdogan's supporters celebrated well into the night after Turkey's long-time president secured another five years in power.
"The entire nation of 85 million won," he told cheering crowds outside his enormous palace on the edge of Ankara.
But his call for unity sounded hollow as he ridiculed his opponent Kemal Kilicdaroglu - and took aim at a jailed Kurdish leader and the LGBT community.
The opposition leader did not explicitly concede victory.
Complaining of "the most unfair election in recent years", Mr Kilicdaroglu said the president's political party had mobilised all the means of the state against him.
President Erdogan ended with just over 52% of the vote, based on near-complete unofficial results. Almost half the electorate in this deeply polarised country did not back his authoritarian vision of Turkey.
Ultimately, Mr Kilicdaroglu was no match for the well-drilled Erdogan campaign, even if he took the president to a run-off second round for the first time since the post was made directly elected in 2014.
But he barely dented his rival's first-round lead, falling more than two million votes behind.
The president made the most of his victory, with an initial speech to supporters atop a bus in Turkey's biggest city, Istanbul, followed after dark by a balcony address from his palace to an adoring crowd that he numbered at 320,000 people.
"It is not just us who won, Turkey won," he declared, calling it one of the most important elections in Turkish history.
He taunted his opponent's defeat with the words "Bye, bye, Kemal" - a chant that was also taken up by his supporters in Ankara.
Mr Erdogan poured scorn on the main opposition party's increase in its number of MPs in the parliamentary vote two weeks earlier. The true number had fallen to 129, he said, because the party had handed over dozens of seats to its allies.
He also condemned the opposition alliance's pro-LGBT policies, which he said were in contrast with his own focus on families.
The run-up to the vote had become increasingly rancorous. In one incident, an opposition Good party official was fatally stabbed in front of a party office in the northern coastal town of Ordu.
The motive for Erhan Kurt's killing was not clear, but a leading opposition official blamed youths celebrating the election result.
Although the final results were not confirmed, the Supreme Election Council said there was no doubt who had won.
It is highly unusual for the palace complex to be opened to the public - but so was this result, extending his period in power to a quarter of a century.
Supporters came from all over Ankara to taste the victory. There were Islamic chants, while some laid Turkish flags on the grass to pray.
For a night, Turkey's economic crisis was forgotten. One supporter, Seyhan, said it was all a lie: "Nobody is hungry. We are very happy with his economy policies. He will do even better in the next five years."
But the president admitted that tackling inflation was Turkey's most urgent issue.
The question is whether he is prepared to take the necessary measures to do so. At an annual rate of almost 44%, inflation seeps into everyone's lives.
The cost of food, rent and other everyday goods has soared, exacerbated by Mr Erdogan's refusal to observe orthodox economic policy and raise interest rates.
The Turkish lira has hit record lows against the dollar and the central bank has struggled to meet surging demand for foreign currency.
"If they continue with low interest rates, as Erdogan has signalled, the only other option is stricter capital controls," warns Selva Demiralp, professor of economics at Koc university in Istanbul.
Economics was far from the minds of Erdogan supporters, who spoke of their pride at his powerful position in the world and his hard line on fighting "terrorists", by which they meant Kurdish militants.
President Erdogan has accused his opposite number of siding with terrorists, and criticised him for promising to free a former co-leader of Turkey's second largest opposition party, the pro-Kurdish HDP.
Selahattin Demirtas has been languishing in jail since 2016, despite the European Court of Human Rights ordering his release.
Mr Erdogan said while he was in power, Mr Demirtas would stay behind bars.
He also promised to prioritise rebuilding in areas hit by February's twin earthquakes and bring about the "voluntary" return of a million Syrian refugees.
Crowds flocked to Istanbul's Taksim Square, with many coming from the Middle East and the Gulf.
Palestinians from Jordan wrapped Turkish flags around their shoulders. A Tunisian visitor, Alaa Nassar, said Mr Erdogan had not just made improvements to his own country, "he is also supporting Arabs and the Muslim world".
For all the celebrations, the idea of unity in this polarised country seems farther away than ever.
Since a failed coup in 2016, Mr Erdogan has abolished the post of prime minister and amassed extensive powers, which his opponent had pledged to roll back.
One voter outside an Ankara polling station on Sunday said he wanted to see an end to the brain drain that began with the post-coup purge. There is a risk that it may now intensify.
Turkey's defeated opposition will now have to regroup ahead of local elections in 2024.
Istanbul Mayor Ekrem Imamoglu, a high-profile favourite among opposition supporters, appealed to them not to despair.
He reminded them on Monday that the opposition had defeated the ruling party in Ankara and Istanbul in 2019 months after they had lost the last presidential election.
That was only achieved after they changed strategy and started from scratch, he explained: "We will never expect different results by doing the same things."
Additional reporting from Istanbul by Cagil Kasapoglu.
Super Morning Show wins CIMG Radio Programme of the Year 2022
Myjoyonline.com wins CIMG ’Online News Portal’ for the second year running
Tottenham 2-1 Liverpool: PGMOL admits ‘significant human error’ over disallowed Luis Diaz goal
Premier League: Tottenham beat nine-man Liverpool with late own goal
Government, Global Mercyship partner to offer free surgical care
Nkrabeah Effah-Dartey: Swan song for Alan Kyerematen
Police to grant NDC security for demonstration against BoG
CAF Confederation Cup: Dream FC edge Kallon to reach group stage on first attempt
CAF CL: Medeama see off Horoya to become first Ghanaian team to reach group stage in 11 years
Internal Democracy in Ghana’s Political Parties: Elections or Elites’ Selections?
Ike Tandoh: Cry, my beloved country
Stonebwoy returns to Australia after 7 years with an epic performance at Promiseland Festival
Tsito-Anyirawase culvert repaired by First Sky Group, highway reopens
Amanda Clinton: 13 reasons why Ghana doesn’t need a coup
Lands Minister admonishes media to partner government on combating nature crimes