The election is the first popularity test of the UNP-led government since the April 21 suicide bomb attacks that killed at least 269 people.
Colombo: Sri Lanka's former wartime defence secretary Gotabaya Rajapaksa has been elected president, his spokesman said Sunday following a fiercely fought election seven months after terror attacks killed 269 people.
The 70-year-old retired lieutenant colonel had a 48.2 percent share of the vote with close to three million ballots counted but results from Sinhalese-majority regions -- the Rajapaksas' core support base -- were expected to push this above 50 percent.
"We got between 53 to 54 percent," his spokesman Keheliya Rambukwella told AFP.
"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," Rambukwella said.
Sri Lanka's ruling party candidate Sajith Premadasa conceded the presidential poll on Sunday and congratulated his main rival, former wartime defence secretary Gotabaya Rajapaksa.
"It is my privilege to honour the decision of the people and congratulate Mr. Gotabaya Rajapaksa on his election as the seventh President of Sri Lanka," Premadasa said.
Election Commission chairman Mahinda Deshapriya said at least 80 percent 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 terror group.
Three luxury hotels and three churches were targeted in the coordinated bombings. ISIS too 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.
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 and projected 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 credited with directing security forces to crush Tamil rebels and end a 37-year separatist war in May 2009 during the tenure of his elder brother Mahinda, who was president from 2005 to 2015.
The Rajapaksas are adored by Sri Lanka's Sinhalese majority, as well as the powerful Buddhist clergy, for defeating Tamil Tiger separatists and ending a 37-year civil war in 2009.
But they are detested and feared by many Tamils, who make up 15 percent 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 10 percent 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.