But he said the inquiry would answer critics who have said the government has been unwilling to hold a "comprehensive" inquiry into the Iraq war and its aftermath.
"Now that British troops are home, it is right that we have a genuinely comprehensive inquiry and I also think it's worth pointing out that the prime minister's made clear that when the report is published, everything except the most sensitive aspects of national security will be published."
John Miller, whose son Simon was killed in Iraq in 2003, said private hearings would be marred by "lies and deceit".
But others argued that closed proceedings would be more effective.
Tory MP Michael Mates, who was part of the Butler inquiry into the intelligence that led to the Iraq war, backed the prime minister's decision.
"Everybody who came in front of us... was able to speak frankly and they were able to say what part they had played in this bit of intelligence or that," he told the BBC.
"I don't think we could have done as good a job for the country as we were able to do if we had to sit in public."
'Full and candid'
The inquiry will start in July and take at least a year to complete. It will cover the period from July 2001 to July 2009 and be chaired by civil servant Sir John Chilcot.
It will not seek to "apportion blame", the prime minister said, but will aim to identify "lessons learned".
The government had been urged to hold it in public, but Mr Brown said privacy would ensure that evidence given by politicians, military officers and officials would be as "full and candid as possible".
Mr Cameron accused the prime minister of reneging on promises he made just a week ago to introduce a "new era of democratic renewal" and make politics more transparent.
"The inquiry needs to be, and needs to be seen to be, truly independent and not an establishment stitch-up," the Tory leader said.
Former Lib Dem leader Sir Menzies Campbell rejected claims that a public enquiry would cost too much, insisting it would be "well worth the money if it stopped us making the same kind of mistake again".
The present leader, Nick Clegg, who has threatened to boycott any private hearing, said it would be possible for a public inquiry to handle sensitive information by hearing some sessions on an exceptional basis behind closed doors.
Mr Clegg told the BBC: "This, remember, was probably the biggest foreign policy mistake that any government has made since Suez.
"It's very important the the process by which we learn the lessons from that is open - the process of doing it is almost as important as the conclusions themselves."
'Day of reckoning'
"This would have been a great moment for Gordon Brown, who has said he wanted more openness and transparency in politics, to show he meant it."
Several of Mr Brown's own Labour MPs also spoke out in favour of full disclosure.
Gordon Prentice said he was "not prepared to accept a secret inquiry into Iraq", while David Hamilton said there needed to be a "day of reckoning" which could only come about through public proceedings.
Their feelings were echoed by relatives of those killed in Iraq.
It will give us some sort of government narrative that can then be picked apart
Maj Charles Hayman Armed Forces UK
Mr Miller said that without apportioning any blame, the inquiry could not possibly deliver any real answers.
"To be honest, I could write on the back of a stamp what you would learn from this inquiry and that would be lies and deceit," he told the BBC.
But Maj Charles Hayman, editor of Armed Forces UK, said the inquiry would bring significant facts "into the open".
"It's not going to go as far as most people would have wanted, but it will certainly open the Pandora's box to the whole of this Iraq problem," he said.
"It will give us some sort of government narrative that can then be picked apart."
Sir John Chilcot, 70, is a former permanent under-secretary of state at the Northern Ireland Office who sat on the Butler Inquiry into the intelligence on Iraq's weapons of mass destruction.
Also on the panel are former diplomat Sir Roderick Lyne, crossbench peer Baroness Prashar and historians Sir Lawrence Freedman and Sir Martin Gilbert.
The reasons for going to war in Iraq - including the now discredited claim that Saddam Hussein had weapons of mass destruction which could be used within 45 minutes of an order being given - have been a source of long-standing controversy.
Two inquiries - the Hutton and Butler inquiries - have already been held into aspects of the Iraq war.
The Butler inquiry looked at intelligence failures while the Hutton inquiry examined the circumstances leading to the death of former government adviser David Kelly.
In 2008, the government defeated Conservative attempts to force a public inquiry, saying it would be a "diversion" for UK troops serving in Iraq.
In February, Justice Secretary Jack Straw vetoed the publication of minutes of cabinet meetings discussing the legality of the war in the run-up to the invasion.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.