The new plant will process ash from the incinerator in Splott, Cardiff. The waste, known as incinerator bottom ash (IBA), contains glass and metals that are left over after refuse is burned.

But the application for a judicial review of the case was rejected by a top judge.

In a statement published on its website, the Vale of Glamorgan council said: “The judge, The Hon. Mr Justice Coulson, stated that the application for judicial review “must fail” as it amounted to an attempt to reargue the merits of the original decision and was therefore without foundation.”

The authority’s head of regeneration and planning, Marcus Goldsworthy, added: “The council is extremely pleased with this decision which vindicates all the hard work of both officers within our planning team and the members of the planning committee itself.

“This application was considered properly and thoroughly prior to committee making a well-informed and reasoned decision.

“The council will now be seeking to ensure that all of the costs it incurred in defending its decision in the courts are recovered from the claimant.”

Victoria Hutton, who represented the campaigners, had earlier said: “What’s at the heart of this challenge is a genuine concern by the claimant and other local residents as to the nature of IBA and its effect on health and ecology.”