Barcelona has banned older more polluting cars and is mulling the idea of a congestion charge as well

Barcelona imposed a ban Thursday on older, more polluting vehicles during most of the day in a bid to reduce air pollution in Spain's second largest city.

Gasoline-powered cars registered in Spain before 2000, and diesel-powered cars registered before 2006 are now banned from most city streets on weekdays between 7:00 am and 8:00 pm and face a fine of at least 100 euros ($112) if they violate the rule.

All banned vehicles will be allowed to enter the city 10 times a year.

Owners of vehicles registered outside of Spain can request permission from city hall to drive in the Mediterranean coastal city which is home to 1.6 million people.

Beginning in 2021 older, more polluting vans, trucks and buses will also be banned..

The new rules are expected to affect around 50,000 vehicles a day and lead to a 15-percent cut in nitrogen dioxide emissions, a poisonous gas in car exhaust.

Since last year, Madrid has restricted driving in the old city centre to people who live there. Residents from outside the area can only drive there if they use an electric or other low-emissions vehicle.

While that rule is more restrictive than the policy put in place in Barcelona, the area of Madrid that is affected is much smaller.

Barcelona's far-left mayor Ada Colau has raised the possibility of introducing a like those in place in other European cities such as London, Stockholm and Milan.

Barcelona has since 2002 exceeded the level of airborne carbon dioxide set by the European Union, according to a 2017 report by the city public health department.

The 's caused a yearly average of 424 between 2010 and 2017, the report said.

Last year Brussels asked the European Union's Court of Justice to take action against Spain for its "systemic violations" of rules limiting nitrogen dioxide emissions.