Theresa May’s government is committed to introducing an ‘Alan Turing law’ and will, in due course, pardon thousands of gay men convicted under historic gross indecency crimes.

Sources close to the Prime Minister confirmed to The Independent that Ms May's government is “committed” to introducing the legislation, which will effectively act as an apology while the Ministry of Justice added they would “now find the right legislative vehicle to push this through”.

“This government is committed to introducing posthumous pardons for people with certain historical sexual offence convictions who would be innocent of any crime now. We will bring forward our proposals in due course,” a government spokesperson added.

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 in England in 1967.

The family of Alan Turing deliver the change.org petition to Downing Street signed by almost half a million people calling for more than 49,000 British gay men convicted under historic anti-gay laws in the UK

Speaking to The Independent, Rachel Barnes, Mr Turing’s great-niece said she had been “disappointed that there had been no progress” since she and others had originally launched a petition in 2015 to extend her great-uncle’s pardon to all men convicted under the historic laws. “I will give my backing towards any progress,” she added.

“It’s something the family of Alan Turing have always, always backed and we really do want justice for everybody who was affected by the anti-gay laws. I am very pleased to hear the current administration will give it their backing."

It comes after campaigners, and the family of Mr Turing – who according to Winston Churchill “made the single biggest contribution to the allied victory" in World War II – delivered the petition to Downing Street in 2015 before the general election. Public pressure led to the major political parties pledging to right the wrongs of the past and introduce what was dubbed as the 'Alan Turing law', in memory of the Bletchley Park codebreaker.

The 2015 Conservative manifesto stated: “We will build on the posthumous pardon of Enigma codebreaker Alan Turing, who committed suicide following his conviction for gross indecency, with a broader measure to lift the convictions of this nature. Thousands of British men still suffer from similar historic charges, even though they would be completely innocent of any crime today.

Codebreaker Alan Turing (Rex Features)

"Many others are dead and cannot correct this injustice themselves through the legal process we have introduced while in government. So we will introduce a new law that will pardon those people, and right these wrongs.”