Gotabaya Rajapaksa, who spearheaded the brutal crushing of the Tamil Tigers 10 years ago, stormed to victory on Sunday in Sri Lanka's presidential elections seven months after extremist attacks killed 269 people.
The retired lieutenant colonel, nicknamed the "Terminator" by his own family, won 53-54 per cent of the vote, his spokesman told AFP as Rajapaksa's main rival Sajith Premadasa of the ruling party conceded the race.
"It is a clear win. We envisaged it. We are very happy that Gota will be the next president. He will be sworn in tomorrow or the day after," spokesman Keheliya Rambukwella said.
Rajapaksa, 70, had a 49.6pc share of the vote with close to six million ballots counted. He is the younger brother of the charismatic but controversial Mahinda Rajapaksa, who was president from 2005-15.
Results from Sinhalese-majority regions — the Rajapaksas' core support base — were expected to push this above 50pc.
Premadasa, 52, of the ruling party was trailing at 44.4pc. He had strong support in minority Tamil areas and a poor showing in larger Sinhalese constituencies.
Election Commission chairman Mahinda Deshapriya said at least 80pc of the 15.99 million eligible voters participated in Saturday's poll, which was marred by isolated violence that left several people injured.
Rajapaksa conducted a nationalist campaign with a promise of security and a vow to crush religious extremism in the Buddhist-majority country following the April 21 suicide bomb attacks blamed on a homegrown jihadi group.
Three luxury hotels and three churches were targeted in the coordinated bombings. The militant Islamic State group also claimed responsibility for the attack, which left 45 foreigners dead.
Saturday's poll was the first popularity test of the United National Party (UNP) government of Prime Minister Ranil Wickremesinghe, who stepped aside and allowed his deputy Premadasa to stand in the election.
Pakistan felicitates newly-elected president
In a press release issued by the Foreign Office (FO), the government and leadership of Pakistan felicitated the newly-elected president.
"Pakistan is confident that under his stewardship, Sri Lanka will continue its journey towards greater prosperity and peace," the press release stated, adding that the country's leadership looks forward to working with the new president and his team to "further strengthen the already strong relationship between the two countries".
"The government of Pakistan expresses the resolve to further fortify the fraternal ties and to take this vital partnership to a new level," it read.
Pakistan appreciated the conduct of "free, fair and peaceful elections" by the Sri Lankan government and election commission.
Wickremesinghe's administration faced severe criticism for failing to prevent the attacks despite prior warnings from an intelligence agency of neighbouring India, according to findings of a parliamentary investigation.
Premadasa also offered better security and a pledge to make a former war general, Sarath Fonseka, his national security chief, projecting himself as a victim seeking to crush terrorism.
He is the son of assassinated ex-president Ranasinghe Premadasa who fell victim to a Tamil rebel suicide bomber in May 1993.
Gotabaya is adored by the Sinhalese majority and by the powerful Buddhist clergy for directing security forces to crush Tamil separatists and end a 37-year separatist war in May 2009 with brother Mahinda.
But they are detested and feared by many Tamils, who make up 15pc of the population. The conflict ended with some 40,000 Tamil civilians allegedly killed by the army.
Some in the Muslim community, who make up 10pc of the population, are also fearful of Gotabaya becoming president, having faced days of mob violence in the wake of the April attacks.
Under his brother, Gotabaya was defence secretary and effectively ran the security forces, allegedly overseeing "death squads" that bumped off rivals, journalists and others. He denies the allegations.
During that time, Sri Lanka also borrowed heavily from China for infrastructure projects and even allowed two Chinese submarines to dock in Colombo in 2014, alarming Western countries as well as India.
The projects ballooned Sri Lanka's debts and many turned into white elephants — such as an airport in the south devoid of airlines — mired in corruption allegations.
China also offered Sri Lanka "international diplomatic protection" against criticism for its rights record, analyst Paikiasothy Saravanamuttu told AFP.
The Rajapaksas "spent and spent without giving any consideration to how it has to be paid back".
Unlike in 2015 when there were bomb attacks and shootings, this election was relatively peaceful by the standards of Sri Lanka's fiery politics.
The only major incident was on Saturday when gunmen fired at two vehicles in a convoy of at least 100 buses taking voters from the Muslim minority to vote. Two people were injured.
After a campaign that according to the Election Commission was the worst ever for hate speech and misinformation, final results could come by later Sunday.