Vince Cable will remain as business secretary but has been stripped of his responsibilities for media and telecoms after being slapped down by David Cameron for telling undercover reporters he had "declared war" on Rupert Murdoch.

Cable, the second most senior Lib Dem figure in the coalition government, hung on to his cabinet seat despite the comments which referred to his intervention on public interest grounds in News Corporation's bid for full control of BSkyB.

Cable was called to Downing Street to be told that he will play no further part in the BSkyB decision. He has also lost all responsibility for competition and policy issues relating to media, broadcasting, digital and telecoms which will be transferred immediately to Jeremy Hunt, the Conservative secretary of state for Culture, Media and Sport (DCMS).

A Downing Street statement made clear Cameron's anger over the secretly recorded comments by the Daily Telegraph. "The prime minister is clear that Mr Cable's comments were totally unacceptable and inappropriate."

In a statement later Cable said: "I fully accept the decision of the prime minister and deputy prime minister. I deeply regret the comments I made and apologise for the embarrassment that I have caused the government."

Labour leader Ed Miliband called for Cable to be sacked, saying that he appeared to have breached the ministerial code on objectivity in decision-making. "David Cameron has made the wrong judgment and he has kept Vince Cable on, not because of the national interest but because his Conservative-led government needs the prop which Vince Cable provides.

"Vince Cable should have gone. Having apparently breached the ministerial code and having said what he said, he shouldn't be remaining in office."

Cable's Labour shadow John Denham, who had called on him to step aside from the BSkyB decision and questioned how he could remain in the cabinet, said: "David Cameron has decided to hang on to a lame duck business secretary who has no credibility. Vince Cable has been removed from one of the most important decisions in the department. He has revealed how the government is paralysed by infighting. The only reason for holding on to him is to keep the sagging tent of this Tory-led government upright but at the expense of British business."

The prime minister took action after Cable told two undercover reporters from the Daily Telegraph posing as mothers concerned about benefit changes: "I am picking my fights, some of which you may have seen, some of which you may haven't seen [sic].

"And I don't know if you have been following what has been happening with the Murdoch press, where I have declared war on Mr Murdoch and I think we are going to win."

The outburst was held back from the Telegraph's front-page story today, which focused on his claims that he could "bring the government down" by walking out of the coalition if "pushed too far" in negotiations with Tory ministers.

He confided that being in the coalition was "like fighting a war" and that he could use the "nuclear option" of quitting.

Cameron appeared relaxed about Cable's views on the coalition government, saying only that Cable had "every reason to be embarrassed" by his comments on working in coalition with the Conservatives.

But it turned out to be his unpublished comments, which were revealed by the BBC's Robert Peston just minutes after Cameron and deputy prime minister Nick Clegg held an "end of term" press conference, which proved to be the senior Lib Dem minister's undoing after appearing to prejudge the outcome of Ofcom's investigation into whether the News Corp bid should be investigated on media plurality grounds, which was ordered by Cable. Ofcom is due to report by the end of the year.

Peston, a former city editor of the Sunday Telegraph, who said he was passed the transcript by a whistleblower "upset that the Telegraph chose to omit these remarks" revealed that Cable told the two reporters: "I have blocked it using the powers that I have got and they are legal powers that I have got. I can't politicise it but from the people that know what is happening this is a big, big thing. His whole empire is now under attack ... So there are things like that we do in government, that we can't do ... all we can do in opposition is protest."

News Corp was quick to condemn Cable's remarks. A spokeswoman said: "News Corp is shocked and dismayed by reports of Mr Cable's comments. They raise serious questions about fairness and due process."

The company is believed to have been encouraged earlier today by the European Commission's decision to clear the bid on competition grounds.

Peston told the BBC News channel: "It's extremely clear that News Corp will say categorically that he [Cable] cannot now make the decision on this takeover. If he can't, either they have to find a mechanism for someone else to make the decision or he has to resign. Those are the only options for Mr Cable. He has to do quite a lot of explaining quite quickly."

Cable, the highest-ranking Lib Dem member of the coalition after Clegg, the deputy prime minister, said last night he was "embarrassed" by his remarks about the coalition government, but had no intention of resigning over the comments.

Asked at the press conference whether he was personally embarrassed at Cable's behaviour, Clegg said: "He himself has said he was embarrassed by the comments he was reported as saying and I can totally understand why he was. End of story."

Telegraph Media Group is part of an alliance of rival media organisations, with the publishers of the Guardian, Daily Mail and Daily Mirror, opposed to News Corp acquiring the 61% of Sky it does not already own.

• To contact the MediaGuardian news desk email editor@mediatheguardian.com or phone 020 3353 3857. For all other inquiries please call the main Guardian switchboard on 020 3353 2000.

• If you are writing a comment for publication, please mark clearly "for publication".