Thousands of gay and bisexual men convicted under outdated gross indecency laws are to be posthumously pardoned, the Government has announced, in a “momentous” victory for campaigners.

Announcing what has been dubbed as the ‘Alan Turing law’ justice minister Sam Gyimah said the Government would seek to implement the change through an amendment to the Policing and Crime Bill. It will effectively act as an apology to those convicted for consensual same-sex relationships before homosexuality was decriminalised in England and Wales in 1967.

Last month sources close to Theresa May confirmed to The Independent that the Prime Minister was “committed” to introducing the legislation. The Ministry of Justice believes this amendment is the quickest possible way to deliver on the commitment.

It comes after decades of campaigning from the LGBT community and after the family of the enigma codebreaker Alan Turing delivered a petition to Downing Street before the 2015 general election. Public pressure led to the major political parties pledging to introduce the ‘Alan Turing law’ – in memory to the man Winston Churchill described as making “the single biggest contribution to the allied victory” in World War II.

Speaking to The Independent today, Rachel Barnes, the great niece of Mr Turing, who has long campaigned on the issue, hailed the decision as “absolutely tremendous”.

She said: “This is a momentous day for all those who have been convicted under the historic laws, and for their families. The gross indecency law ruined peoples’ lives. As Alan Turing received a pardon, it is absolutely right that those who were similarly convicted should receive a pardon as well. It is great news for all those who have worked so hard for years to bring about this new legislation”.

Mr Turing, the Enigma code breaker responsible for decrypting Nazi messages, was granted a posthumous royal pardon in 2013 – 61 years after he was charged at Manchester police station over homosexual activity.

The pioneering mathematician, whose code-breaking skills are said to have shortened World War Two by two to four years, lost his job with the secret service following a conviction for gross indecency and was forced to undergo chemical castration by a series of injections of female hormones. Two years later Mr Turing took his own life – and it is estimated that around 49,000 were convicted under similar outdated laws until homosexuality was decriminalised.

The family of Alan Turing delivered a change.org petition to Downing Street signed by almost half a million people calling for more than 49,000 British gay men to be officially pardoned

The amendment to the Policing and Crime Bill – now supported by the Government – was put forward by the Liberal Democrat peer Lord Sharkey, who said today “is a momentous day for thousands of families up and down the UK who have been campaigning on this issue for decades.”

He added: “I am very grateful for the Government’s support and the support of many of my colleagues in Parliament.

“It is a wonderful thing that we have been able to build on the pardon granted to Alan Turing during Coalition by extending it to the thousands of men convicted of sexual offences that existed before homosexuality was decriminalised in 1967 and which would not be crimes today.”

In another step, the Government is also announcing that it will introduce a new statutory pardon for the living in cases where offences have been successfully deleted through the disregard process.

Mr Gyimah added: “It is hugely important that we pardon people convicted of historical sexual offences who would be innocent of any crime today. Through pardons and the existing disregard process we will meet our manifesto commitment to put right these wrongs.”

However, anyone living who has been convicted of the now abolished offences can currently apply through the Home Office to have their names cleared through the disregard process. This removes any mention of an offence from criminal record checks.

The Government said it will not support a separate Private Member's Bill on the subject, which is set to be debated on Friday and proposes a blanket pardon for the living without the need to go through the disregard process.

“A blanket pardon, without the detailed investigations carried out by the Home Office under the disregard process, could see people guilty of an offence which is still a crime today claiming to be pardoned,” Mr Gyimah added.