Mary Harper Africa editor, BBC World Service
Senegal’s governing party has admitted defeat in the capital Dakar and the southern city of Ziguinchor in Sunday’s local elections.
The polls were seen as a test of the government’s popularity ahead of general elections in 2024.
Parties linked to two of President Macky Sall’s fiercest rivals defeated his Bennoo Bokk Yaakaar coalition – Barthelemy Dias to set to become mayor of Dakar, and Ousmane Sonko the mayor of Ziguinchor.
President Sall has become increasingly unpopular since deadly riots last year over the arrest of Mr Sonko.
Mr Sonko is considered one of the main contenders to replace Mr Sall, who is supposed to stand down after two terms.
Mr Dias is an ally of former Dakar mayor Khalifa Sall (no relation to the president), who was jailed in 2018 on corruption charges that were widely seen as a way of sidelining a political rival.