Home Secretary Theresa May has been accused of seeking to introduce Government censorship of the media by one of her Cabinet colleagues.

In a letter to David Cameron written before the general election, then Culture Secretary Sajid Javid attacked Ms May’s plan to use regulator Ofcom to vet programmes before they were broadcast in the strongest terms, saying it posed a threat to freedom of speech.

Mr Javid, now Business Secretary, also said Ofcom would be turned from a regulator into a state “censor” by the proposal and lead to comparisons with “regimes” with dubious human rights records, according to the letter which was leaked to The Guardian newspaper.

The Home Secretary had drawn up plans that would allow Ofcom to prevent programmes containing “extremist content” – such as propaganda by Islamist extremists and their apologists – from being broadcast. This followed anger that BBC Newsnight had interviewed Anjem Choudary, an Islamist activist, following the murder of Drummer Lee Rigby in 2013.

However, in his letter, Mr Javid argued Ofcom’s current rules already prohibited broadcasts that would “incite hatred”.

“Ofcom does not have the powers to approve programmes before they are broadcast and nor do we consider that it should have these powers as has been proposed,” he said.

“Extending Ofcom’s powers to enable it to take pre-emptive action would move it from its current position as a post-transmission regulator into the role of censor.

“This would involve a fundamental shift in the way UK broadcasting is regulated, away from the current framework which is designed to take appropriate account of the right to freedom of expression.”

It was, he agreed, “absolutely vital” that the Government take steps to protect society from extremism.

But he added: “It must also continue to protect the right to freedom of expression and ensure that these proposals do not restrict or prevent legitimate and lawful comment or debate.

“It should also be noted that other countries with a pre-transmission regulatory regime are not known for their compliance with rights relating to freedom of expression and government may not wish to be associated with such regimes.

“I am concerned about the risk that the powers would be used otherwise than intended, not least given the difficulty of defining extremism, and the consequent likelihood of the Government being seen to be interfering with freedom of speech without sufficient justification.”

The Guardian said the outcome of the Cabinet-level dispute was unknown.