The Court of Appeal has upheld the legality of Government cutbacks in the benefits system that campaigners say are pushing people "to breaking point".
Christian leaders have warned that "cutbacks and failures" in the system are forcing thousands of people to use food banks.
But appeal judges have ruled that two of the Government's most controversial cutting measures - the so-called "bedroom tax" and the benefit cap - are not unlawful.
Lord Dyson, Master of the Rolls, rejected a two-pronged legal attack and said the court could only intervene if the measures "were manifestly without reasonable foundation".
The judge ruled that that test was not satisfied and both challenges must fail.
Later campaigners vowed to fight on, saying the cuts are having a "devastating" impact on vulnerable people.
The Department for Work and Pensions, which was a defendant in both legal actions, welcomed the court's ruling.
A spokesman said of its bedroom policy: "We are pleased that the courts have once again found in our favour and agreed our policy is lawful.
"Reform of housing benefit in the social sector is essential to ensure the long-term sustainability of the benefit. But we have ensured extra discretionary housing support is available for vulnerable people."
Referring to the benefit cap, the spokesman added: ""We are pleased that the courts have ruled again that the benefit cap complies with the European Convention on Human Rights.
"The benefit cap sets a fair limit to what people can expect to get from the welfare system - so that claimants cannot receive more than £500 a week, the average household earnings."
Lord Dyson sat with Lord Justice Longmore and Lord Justice Ryder to hear the bedroom challenge. In a separate hearing, he considered the legality of the benefit cap with Lord Justice Longmore and Lord Justice Lloyd Jones.
The bedroom regulations, introduced in April last year, have led to reductions in housing benefit payments to tenants in social housing assessed through controversial "size criteria" to be under-occupying their accommodation.
Tenants with one spare bedroom have had a payment reduction of 14% and those deemed to have two or more spare have seen a reduction of 25%.
Campaigners say the regulations have had a "devastating" impact on many people by imposing an "excessive and unfair burden" and failing to reflect the needs of disabled people for extra space because of their health problems.
The DWP rejects the ''bedroom tax'' tag and says the reality is that ''a spare room subsidy'' has been removed from social sector tenants.
It says the Government's aim of reducing rising housing benefit expenditure is lawful and legitimate, and an ''integral aspect'' of its deficit reduction programme. The change in regulations is expected to produce savings of £500 million a year.
In the benefit cap case, it was argued the Government's flagship cutbacks policy is having a particularly harsh impact on women fleeing domestic violence, and on their children, threatening to trap them in abusive relationships.
The case was brought by two lone parents forced into temporary accommodation in London, and one each of their children.
The cap forms part of Government reforms to reduce spending on welfare by £11 billion per year.
Lawyers for disabled people affected by the spare bedroom policy said they were "baffled" by today's ruling as it fails to provide legal protection for people with disabilities.
The National Housing Federation's head of policy Kevin Williamson said the launching of court action shows "how desperate" disabled people are.
He said: "Disabled people across the country are being forced to cut back on food and heating to pay the bedroom tax.
"The Government said discretionary housing payments would protect them but one in three disabled people who applied for it were turned down."
Lawyers for lone parents affected by the benefit cap say the court is supporting a measure that is likely to have "not only devastating consequences for individual children but serious financial costs as the fallout impacts on other public services, including social services, education and the justice system."