Senegal's opposition leader Ousmane Sonko was arrested in the capital Dakar on Wednesday, his lawyers said, after supporters scuffled with security forces ahead of hjs scheduled court appearance to face a rape charge.
Sonko, 46, had been heading to court to face a charge that he says is politically motivated.
Hundreds of supporters followed his motorcade, sounding car horns and singing traditional songs, AFP journalists saw.
Afterwards, some Sonko supporters hurled stones at the officers, who fired back wth tear gas.
"He has been notified of his arrest on charges of disturbing public order and participating in an unauthorised demonstration," one of Sonko's lawyers, Cheikh Khouraissy Ba, told AFP.
Another of his lawyers, and Senegal's gendarmerie, confirmed the opposition leader's arrest.
Controversy has dogged Sonko since last month, when Senegalese media reported that an employee at a salon where he went to get massages filed rape charges against him.
The leader of the opposition Pastef party challenged President Macky Sall in the 2019 vote, eventually finishing third in a race that delivered the incumbent a second term.
Sonko has denied the charges and accused the president of conspiring to remove him ahead of 2024 elections.
He was due to appear before a judge in Dakar on Wednesday morning to answer to the rape charge.
However he was arrested before he reached the courthouse, according to his lawyer.
Senegal's national assembly stripped Sonko of his legal immunity as an MP last week, paving the way for a police investigation.
Despite initially saying he would refuse to cooperate -- citing procedural irregularities in the lifting of his immunity -- Sonko agreed to attend a court summons.
"We will go to the judge, but it is not an abdication," he told reporters on Tuesday.
The Sonko affair has drawn analogies with Karim Wade, the son former Senegalese President Abdoulaye Wade, who was convicted for graft and prevented from running in the 2019 election.
Ex-Dakar Mayor Khalifa Sall, a political rival of the incumbent president's, was also jailed in 2017 for fraudulent use of public funds, which stopped him from running for election.
The rape allegation against Sonko also comes as uncertainty grows over whether President Macky Sall, 59, will seek a third term in 2024.
Presidents in the former French colony of about 16 million people are limited to two consecutive terms, but Sall launched a constitutional review in 2016, raising suspicions he intends to run again.
Other presidents in West Africa -- such as Guinea's Alpha Conde or Ivory Coast's Alassane Ouattara -- have used constitutional changes to win third terms.