Mali's Constitutional Court on Monday declared Ibrahim Boubacar Keita president after the 73-year-old incumbent won elections that his opponent, former minister Soumaila Cisse, 68, said were marred by fraud.
Keita was victor in a runoff on August 12 that, according to official results issued by the court after a one-hour session, gave him 67.16 percent of the vote.
He will begin his second five-year term on September 4.
His re-election came despite fierce criticism of failures to tackle jihadist violence and ethnic tensions that have rocked the impoverished Sahel state.
Keita's major challenge as he starts the new term will be to strengthen a 2015 peace accord between the government, government-allied groups and former Tuareg rebels that the government sees as a cornerstone of peace.
Cisse, 68, picked up 32.84 percent of the vote, according to the official results.
He filed a petition to say that that some of the results were rigged. By his calculation he won the election with 51.75 percent of the vote, he said.
But the court rejected his petition as being inadmissible or unsupported by evidence.
"The Constitutional Court has issued a ruling that confirms the fraudulent nature and manipulation of the results," Cisse's campaign chief, Tiebile Drame told AFP, however.
"There's no need for transparent and credible elections in Mali any more."
Observer missions sent by the European Union and the African Union (AU) have said the election was not badly impaired.
Mali, a landlocked nation home to at least 20 ethnic groups where the majority of people live on less than $2 (1.76 euros) a day, has battled jihadist attacks and intercommunal violence for years.
Islamist attacks have spread from the north to the centre and south of the vast country and spilled into neighbouring Burkina Faso and Niger, often inflaming communal conflicts.
France, which intervened to root out jihadists in northern Mali in 2013, still has 4,500 troops in the country.
They are deployed alongside the UN's 15,000 peacekeepers and a regional G5 Sahel force, aimed at fighting the insurgents and restoring the authority of the state in the lawless north.
The economy, alongside security, is the other major challenge facing Keita.
Income per capita has fallen since 2014, according to the World Bank, and nearly half of the 18 million population live in poverty.