His criminal defense lawyer, Michael Pizzi, said the Council was wrong in its interpretation, and that Mr. Thomas had every right to remain in office until Sept. 30.

Lawrence Porcari, the city’s corporation counsel, concurred, issuing a memo outlining what should be the city’s legal position. “Pursuant to the charter and pursuant to law, Mr. Thomas is the mayor, and he is going to be the lawful mayor until or unless some court of competent jurisdiction decided otherwise,” he said in an interview on Wednesday.

“I cannot explain or go into whatever might be motivating the City Council, but our belief is what most of what they engaged in or did in the past weeks was unlawful.”

Then again, Mr. Porcari’s impartiality could be in question: He was indicted in May on charges that he directed $365,000 away from the Mount Vernon Board of Water Supply to pay Mr. Thomas’s legal bills, and hire a public relations firm.

Controversy has dogged Mount Vernon, a small city that credits itself as the inspiration of the Bill of Rights, and is about 65 percent African-American. The promised cleanup of its decaying sports park, Memorial Field, has been in limbo for over a decade; last year, the Justice Department sued the city for violating federal law for its sewer system that dumps raw sewage into the Bronx and Hutchinson Rivers .

In 2014, Mr. Thomas’s predecessor as mayor, Ernest D. Davis , pleaded guilty to federal charges for failing to file personal and corporate tax returns, but the City Council did not invoke the charter’s rules then, and he was permitted to finish out his term. At the time, Mr. Thomas called for Mr. Davis to be removed from office.