Taiwan's President Tsai Ing-wen won a second term on Saturday with a victory over Han Kuo-yu, in an election that had been cast as a referendum on the island's approach to Beijing.
Tsai, from the independence-leaning Democratic Progressive Party (DPP), had been a hot favourite to see off the challenges of Han, from the mainland-friendly Kuomintang (KMT) party, and James Soong Chu-yu, from the People First Party.
Han conceded defeat, saying he had called called Tsai to congratulate her and said he would accept the results.
"My personal efforts were not enough, and I let down all of your expectations."
"On Monday I will return to the Kaohsiung city to go back to work," he said. "I continue to carry the responsibility on my shoulders."
His supporters yelled back" "Check the votes!"
While official counting was still underway, preliminary results showed Tsai had secured at least 57 per cent of the votes, compared with 38 per cent for Han and about 4 per cent for Soong.
Just after 9pm Tsai's vote total had passed 8 million, more than the 6.9 million she received when victorious in 2016 and 7.65 million won by her predecessor Ma Ying-jeou in 2008.
In the DPP headquarters, one of Tsai's supporters said he had been a bit worried when he saw the number of Han's supporters was much bigger than Tsai's at their final campaign rallies, but now he felt excited.
"We are very pleased. It's better than our expectations because Taiwanese have a strong feeling of national demise,"said 43-year-old Tong Chengheng, who works in the finance industry and was celebrating before Han's concession.
This year's elections have been dominated by issues of national sovereignty, democracy and the relationship between Taipei and Beijing amid accusations of mainland interference in Taiwan and the ongoing protest in Hong Kong.
Beijing regards self-ruled Taiwan as part of its territory, a claim rejected by Tsai's administration.
Analysts said Tsai's campaign was boosted by her message of the need to safeguard Taiwan against pressure from Beijing. She has consistently rejected Beijing's assertion that Taiwan should come under the "one country, two systems" model of semi-autonomy, which the mainland applies in Hong Kong.
Tsai is also thought to have benefited from Han's personal gaffes, along with the perception that he was Beijing's preferred candidate, and disunity within the KMT.
Her re-election is likely to see a heightening of cross-strait tensions, as official ties have been suspended since she assumed office in 2016, ostensibly over her refusal to accept the "1992 consensus" - a political understanding that there is only one China with ambiguity over whether it is governed by Taipei or Beijing.
As crowds of Tsai's supporters gathered, footage of someone in the crowd holding a black flag with the words "liberate Hong Kong, revolution of our times" was broadcast on a large screen outside her campaign headquarters in Taipei.
The master of ceremony thanked supporters coming from Hong Kong, and repeated the slogan.
Visitors from Hong Kong in the crowd shouted back the slogan for several times, with some Taiwanese joining in the chant.
In recent years, Beijing has ramped up its efforts to isolate Taiwan on the international stage by wooing its diplomatic allies.
Han, a populist figure who rose to prominence after his surprise win as Kaohsiung mayor in November 2018 regional elections, had called for closer ties with the mainland to ease tensions and boost Taiwan's economy. Following his defeat in the presidential race, he is expected to return to the southern city to resume his mayoral duties.
Taiwan's Foreign Minister Joseph Wu told reporters on Thursday that Beijing should not "read too much" into the Taiwan election and that the island's government would be on alert for any military intimidation, diplomatic isolation or economic repercussions from the election results.
"This is our election - it's not China's election," he said. "If China wants to play with democracies in other countries so much, maybe they can try with their own elections at some point."