The National Secular Society says a Catholic adoption agency in Glasgow should not be allowed to maintain its charitable tax status because it discriminates against same-sex couples.

St Margaret’s Children and Family Care Society had been told in January 2013 by the Scottish Charity regulator that it was to lose its status over its refusal to place children with same-sex couples.

But the decision has now been overturned by the Scottish Charity Appeals Panel.

In response, Terry Sanderson, president of the National Secular Society, said: “This ruling makes some highly dubious claims that need to be tested. Unfortunately it kicks a hole right through the Equality Act.

“It appears to widen the grounds of which religious groups can discriminate against gay people and make it possible to argue that because an organisation has a religious affiliation – even if the primary purposes of the organisation itself are not religious – it can still qualify for charitable status even if it doesn’t comply with the Equality Act.”

Mr Sanderson said the implications of the ruling are wider than this particular case and could permit religious charities to increase their discrimination against gay people without risking the tax advantages that come with charitable status.

Glasgow Archbishop Philip Tartaglia, president of St Margaret’s, welcomed the ruling for his charity: “We are grateful for this wise decision,” he said.

“It means that families who are ready to adopt can look forward to the future with a little more serenity, and children in great need can be placed into loving homes.”

The Office of the Scottish Charity Regulator (OSCR) reviewed the practices of St Margaret’s in January last year, after a complaint from the National Secular Society and, in a report, found it was breaking the Equality Act 2010.

The act states that it’s illegal to refuse to provide goods and services based upon a person’s sexual orientation and gender identity.