MEPs have failed to veto loopholes in air pollution limits on new diesel cars, despite public anger in the wake of the Volkswagen emissions scandal.

Nitrogen oxide (NOx) emissions will now be allowed at twice the EU’s 80mg per km limit from 2019 and 50% more from 2021, despite the exemptions being deemed unlawful in a separate vote by the parliament’s legal committee last night.

At a Strasbourg vote today, MEPs rejected the proposal by 323 votes to 317 - 53 votes short of the absolute majority needed under EU voting rules.

The UK shadow transport minister, Richard Burden, said that MEPs had been put in “an impossible position” by implied threats from several countries – including the UK – to delay the introduction of the new Euro 6 regulations, unless the weakened limits were adopted.

“Government departments colluding in delays to the legislation at earlier crucial stages of this process is not acceptable,” he told the Guardian. “One part of this government appears not to know what the other part is doing.”

The issue of NOx pollution exploded as a political issue in September when Volkwagen was caught using sophisticated software programmes to cheat emissions tests, producing up to 40 times more pollution than allowed.

The RAC’s director, Steve Gooding, hailed today’s vote as “a step in the right direction” as it would cut average NOx emissions from seven times the legal limit to two times.

The automobile industry has argued that it needs “clarity” about the demands being placed on it under the new Real Driving Emissions (RDE) tests. Carmakers say the exemptions in the Euro 6 regulations offer them a vital margin of error in dealing with new measuring equipment.

However, the EU’s science wing, the Joint Research Centre, has estimated testing uncertainties at no more than 20%. Campaigners say that the decision to place the bar at 50% was thus political – and unlawful, given the regulations’ requirement that air quality laws be progressively tightened.

“There’s only one way out of this scandal and that is to have an early review of the flexibility in the new test in 2017,” said Greg Archer, an expert at the Transport and Environment thinktank.

Several MEPs credit pressure from several governments sensitive to car industry demands – and some trades unions – with splitting socialist and liberal groupings in parliament. Sixty-one lawmakers abstained from the RDE vote, enough to have swung the decision the other way.

“Today was a good day for dirty deals and a bad day for cleaner air but the close vote shows there remains strong opposition to the weakening of emission limits,” said the Liberal Democrat MEP Catherine Bearder.

The UK government said that it “strongly supports the current RDE agreement” in an advice document to MEPs seen by the Guardian. The deal would “significantly reduce real world NOx emissions from new diesel cars from 2017,” it argues, going on to say that any delay in its approval would be “likely to result in a significant delay to [its] implementation”.

Even countries with a higher environmental profile, such as Denmark, called on MEPs to back the new exemptions. A letter from the country’s environment minister, Eva Kjer Hansen, stressed that the “conformity factor” allowing a 50% breach of the NOx standard “will be reviewed by the commission and adjusted accordingly. This is a clear result of pressure from Denmark.”

Health professionals though reacted angrily to the news from Strasbourg. The UK’s annual death rate is thought to be about 4% higher because of respiratory illnesses caused by NOx, such as asthma, emphysema and bronchitis.

“Today’s vote in the European parliament is a disaster,” said Dr Penny Woods, the chief executive of the British Lung Foundation. “After the VW emissions affair, now is not the time to weaken legal limits on diesel cars. If the UK government is serious about cleaning up the air we breathe, this decision cannot go unchallenged.”

The Dutch Green MEP, Bas Eickhout, said that a legal petition to the European court of justice was still possible, and called on mayors and city leaders across the continent to take the lead.

“It would be positive if local authorities and mayors pushed their governments to act,” he said. “They are having to take drastic measures such as kicking cars out of city centres while at the same time we are allowing cars to double their emissions at the EU level. If I was mayor of London, I would certainly challenge that.”