BERLIN — A court opened the door on Friday for possible bans on older diesel cars in the German city of Stuttgart, a major auto industry center, upholding a complaint by an environmental group.

The city’s administrative court ordered the state government in Baden-Wuerttemberg to rework a plan to improve the air quality in Stuttgart, saying that it wouldn’t bring improvements sufficiently fast, news agency dpa reported.

The state has been trying to avoid unpopular bans on diesel cars thanks to automakers’ pledges to retrofit vehicles. But judge Wolfgang Kern said that a year-round ban would the most effective way of keeping to permitted nitrogen dioxide levels, which Stuttgart often exceeds.

The Environmental Action Germany group challenged a clean air plan for Stuttgart that is due to take effect in January.

Friday’s ruling leaves open whether, when and how diesel models might be banned. But it increases pressure on German politicians at a time when diesel is under intense scrutiny.

The industry is currently looking for a way out of persistent troubles over excessive diesel emissions, and the government is hosting a meeting with auto bosses next week to discuss ways to reduce them.

In Berlin, federal Transport Minister Alexander Dobrindt said that “blanket driving bans are the wrong political way.”

“It is not our job to ensure that drivers of vehicles that bought them in good faith now have a driving ban imposed on them,” he said. “There will have to be a package of measures for cities in the future.”

Dobrindt acknowledged that “diesel is a transitional technology.” But the German government is reluctant to follow Britain and others in setting a date from which the sale of new cars using diesel and gasoline will be banned.