Kenya's William Ruto will on Tuesday take charge of the East African economic powerhouse after the country's Supreme Court confirmed his narrow victory over veteran politician Raila Odinga in the August 9 poll.
Odinga accepted the ruling but categorically said he did not agree with it, portending political divisions that the country is ill-equipped to cope with as it faces a cost-of-living crisis and a brutal drought.
Here is a look at what lies ahead as the new government takes shape:
Can Ruto mend the political divide?
Kenya's traditional ethnic voting blocs may have ceded ground to class dynamics in this year's polls, but as in the case of previous elections, the result reflected a nation sharply split down the middle.
An effective political strategist, Ruto portrayed the election as a battle between ordinary "hustlers" and "dynasties" -- a reference to Odinga and outgoing President Uhuru Kenyatta, whose families have dominated politics since independence from Britain in 1963.
The 55-year-old deputy president scraped to victory by a margin of less than two percentage points and has struck a conciliatory tone since the results were announced, promising that his government will serve all Kenyans, regardless of political or ethnic affiliation.
According to the Eurasia Group political risk consultancy, "Ruto has worked to co-opt independent lawmakers and weak links in Azimio (Odinga's coalition) to establish an operational majority sufficient to pass legislation and budgets" in parliament.
But Ruto's relationship with Odinga and Kenyatta, former rivals who struck an unlikely alliance ahead of the poll, remains fractious. The outgoing president pointedly failed to publicly congratulate his long-standing deputy for winning the election until the very eve of his inauguration.
How will the economy fare?
Kenya is the most dynamic economy in East Africa but many are suffering deep hardship. Prices for basic goods are skyrocketing in the wake of Covid and the war in Ukraine, and unemployment is a major problem particularly among the young.
Inflation soared to a 65-month high of 8.5 percent in August in the face of a weakening currency, rising fuel costs and a poorly implemented subsidy to halve the price of maize flour used to prepare ugali, a dense porridge that is Kenya's staple food.
Ruto -- who capitalised on growing frustration among Kenya's poor -- has vowed to tackle the cost-of-living crisis and the country's $70-billion debt mountain.
He said he would establish a 50-billion-shilling ($415-million) "hustlers fund" to provide loans to small enterprises to help drive growth and a fertiliser subsidy to reinvigorate farming -- the backbone of the economy that contributes more than 20 percent to GDP.
Florentina Kimoi, who hails from Ruto's Rift Valley bastion of Eldoret, told AFP she hoped the incoming president would pay attention to "long-suffering" farmers like her.
"This year many farmers did not plant cash crops such as maize, cassava (tapioca) and wheat because the prices of fertilisers were too high," said 81-year-old Kimoi.
"In the old days there was a lot of food but things have changed. Nowadays people need money to buy food and earn a livelihood."
What about the fight against corruption?
Ruto has promised to crack down on graft -- a hot-button issue in a country where dozens of leaders are facing charges of embezzling public funds -- but the promise rings hollow to many Kenyans.
Ruto himself boasts a shadowy reputation with graft claims against him going back years, and his scandal-hit running mate Rigathi Gachagua was ordered to forfeit almost $1.7 million in a court ruling following a corruption probe.
In an editorial last week, The Standard newspaper pleaded for Ruto to pick "men and women of integrity" to serve in his administration.
Transparency International ranked Kenya 128th out of 180 in its 2021 corruption perception index, saying the fight against graft had "stagnated".
How will Ruto treat Kenya's neighbours?
Ruto's predecessor Kenyatta devoted a large chunk of his second term to playing peacemaker in East Africa, easing tensions with Somalia, intervening in the crisis in the Democratic Republic of Congo, and hosting talks between Sudan and Ethiopia.
Kenya's allies are anxiously wondering what is next for a country that has evolved into a trusted ally and democratic anchor in a troubled region.
Analysts say the most pressing regional issue will be the fighting in Ethiopia between government forces and rebels that resumed last month, shattering a March truce.
Kenyatta had been touted as a possible mediator and offered Nairobi as a venue for peace talks, which the warring sides have both now agreed should be led by the African Union.