Ekrem Imamoglu, main opposition Republican People's Party (CHP) mayoral candidate, addresses his supporters during a gathering in Istanbul, Turkey, April 12, 2019. REUTERS/Murad Sezer

ISTANBUL (Reuters) - Turkey’s main opposition party candidate Ekrem Imamoglu was declared mayor of Istanbul on Wednesday after recounts of the March 31 local elections were completed, state-owned Anadolu Agency said, citing an opposition lawmaker.

Imamoglu was given the formal mandate despite a pending appeal from President Tayyip Erdogan’s AK Party for the Istanbul election to be annulled and re-run, which the country’s top electoral body has yet to rule on.