Caracas Mayor Antonio Ledezma has been indicted for plotting violence against Venezuela's government - a move condemned by the country's opposition.
The attorney general's office said Mr Ledezma, 59, would remain in a military prison pending his trial.
President Nicolas Maduro earlier accused the opposition mayor of being involved in a US-backed coup.
This comes on the anniversary of the start of protests against Mr Maduro's rule that left dozens of people dead.
On Friday, opponents of the president again protested in the capital against what they described as a crackdown on his political opponents.
The US has also denounced the "systemic intimidation" by the Venezuelan authorities of the country's opposition.
State department spokeswoman Jen Psaki said: "Venezuela's problems cannot be solved by criminalising legitimate, democratic dissent."
Daniel Pardo, BBC News, Caracas
The news of Mr Ledezma's arrest was surprising, but Venezuelans have seen this before. Of 76 opposition mayors in office, 33 are facing a trial.
Last time a prominent opposition politician was jailed - Leopoldo Lopez, a year ago - there were large street protests. But not this time.
Opposition leaders asked people to not take the "government's bait" by staging large protests, a scenario which would make violence more likely. Many analysts argue that protests benefit the government as they create a common threat unifying the government's supporters, and giving Mr Maduro grounds to condemn the opposition.
The opposition's strategy this time is different. It aims to win parliamentary elections later this year by capitalising on Mr Maduro's declining popularity. That would be a outcome not seen for decades in Venezuela.
The attorney general's office said on Friday that Mr Ledezma was charged with conspiracy to plot violence against the government.
This came a day after camouflaged police smashed into the mayor's office in the banking district and carried him away.
President Maduro has said the opposition leader must answer "for all the crimes committed against the country's peace and security".
But the country's opposition is now demanding the authorities produce any evidence of the alleged conspiracy.
Opposition leader Henrique Capriles asked: "Does Maduro think that putting everyone in prison is going to get him 50 popularity points or that he's going to win elections?"
Mr Ledezma was on a list of people and foreign powers named by Mr Maduro last week as attempting to bring down his administration.
Mr Ledezma, Caracas mayor since 2008, replied that it was government corruption that was bringing down Venezuela.
Last year, weeks of anti-government protests led to more than 40 deaths.
Venezuela's economy has been heavily affected by the drop in oil prices and in late January, thousands of Venezuelans joined an opposition march in Caracas.
They voiced dissatisfaction with high inflation, crime and the shortage of many staple goods in the shops.