A new generation of secret courts will be established in law within weeks after a last-ditch bid to water down controversial government plans failed in the House of Lords.

Amnesty International warned of a "terrible day for British justice" after Lib Dem peers obeyed a three-line government whip to reject amendments to strengthen the role of judges in the new courts.

The justice and security bill, which extends the secretive closed material procedures (CMPs) into the main civil courts in England and Wales, will be sent to the Queen for royal assent before she opens a new session of parliament on 8 May.

Tim Hancock, Amnesty International's UK campaigns director, said: "This is a terrible day for British justice. After fierce lobbying by the government, peers have failed to restore even minimal amendments previously included to this deeply damaging bill. The cherished and vitally important principle that justice must be done and seen to be done has been dealt a serious blow this evening."

Kenneth Clarke, the minister without portfolio who championed the bill, says it is necessary to introduce the CMPs to allow sensitive intelligence to be heard in court, though this will be limited to the judge and to special advocates cleared for security who would represent claimants. Clarke claims the government has had to pay compensation to alleged victims of torture because some evidence cannot be heard in open court.

The government won on Tuesday night when peers voted by 174 to 158, a majority of 16, to reject a Labour amendment to allow the CMPs to be convened only if a judge rules that it would be impossible to reach a fair verdict "by any other means".

A separate amendment by Lord Macdonald of River Glaven, the Lib Dem former director of public prosecutions, which would have given judges the power to balance the interests of "national security" and "fair and open administration of justice" was withdrawn.

Lord Beecham, who moved the unsuccessful Labour amendment, said: "[Ken] Clarke's adherence to liberal principles over the years has earned him many admirers in a lifetime in politics, though not necessarily within his own party. I hope that by endorsing these amendments the house can not only help to minimise the damage that threatens the most valued elements of our jurisprudence and judicial system but also help rescue the minister without portfolio from self-inflicted damage on his own reputation for upholding those liberal values as he comes to the end of his most distinguished career."

Macdonald told peers: "The illiberalism inherent in this bill lies in this: that CMPs, as presently constituted, are not fair because they don't deliver and can't deliver balanced justice between the citizen and the state."

Lord Wallace of Tankerness, the Lib Dem advocate general for Scotland who also acts as the attorney general's spokesman in the Lords, said the government had made key changes to the bill to reflect concerns in the Lords after peers had defeated the government during an earlier stage of the bill. Wallace said: "The decision rests with the judge not the secretary of state … what we have sought to do is to ensure that this should be a procedure used only in very exceptional circumstances."

Clare Algar, executive director of the human rights charity Reprieve, said: "This is a disastrous result for British justice. Not only are we now facing a wave of secret courts at odds with our centuries-old legal freedoms; but we have not even seen the minor safeguards upheld which would have made them less dangerous.

"It is deeply shameful that the government has been allowed to push these plans through parliament, despite the total lack of evidence that they are needed. Secret courts will not make us any safer. They will, however, do irreparable damage to our reputation as a country which respects fair play and the rule of law."