London, England (CNN) -- Former British prime minister Tony Blair on Friday rejected claims that he had struck a secret deal with U.S. President George W. Bush in 2002 pledging British backing for the invasion of Iraq.
Testifying in front of the inquiry into the UK's participation in the U.S.-led war against Saddam Hussein's regime in 2003, Blair said he had stated publicly that Iraq needed to be confronted over its ambitions to develop weapons of mass destruction.
But Blair had told Bush that he would be "with him" when the pair met at the U.S. president's Texas ranch in April 2002, he said.
"What I was saying -- I was not saying this privately incidentally, I was saying it in public -- was 'We are going to be with you in confronting and dealing with this threat,' Blair told the inquiry, headed by former civil servant John Chilcot.
"The one thing I was not doing was dissembling in that position. The position was not a covert position, it was an open position."
Blair said that plans for how Iraq should be governed after the invasion had failed to foresee the destabilizing roles played by Iran and al Qaeda, nor problems with Iraq's civil service.
On the matter of the legal basis for the invasion, Blair said U.N. resolution 1441 authorized military action in Iraq without a further resolution -- but admitted "there was always a case either way" and said a second resolution would have been "preferable politically."
"But in the end, we got to the point in the middle of March where frankly we had to decide," Blair said. "We were going either to back away or we were going to go forward and I decided, for the reasons that I've given, that we should go forward."
Several hundred anti-war protesters gathered outside the Queen Elizabeth II Conference Centre, opposite the Houses of Parliament in central London, to mark Blair's appearance at the inquiry, chanting "Blair lied, thousands died!" and "Tony Blair! War criminal!"
Mock pallbearers wearing Blair masks carried a black coffin. Some in the crowd wore "Jail Tony" T-shirts and toted signs saying "Stop the War," "Troops out of Afghanistan." and "Bliar," a deliberate misspelling of his name.
Left-wing lawmaker George Galloway said that Blair's actions in Iraq were "more terrible than the crimes of Macbeth" and called on the former prime minister to "commit hari-kiri in front of the world" on the steps of the conference center.
Relatives of the 179 British troops killed in Iraq were among those admitted to the public gallery.
Blair said he believed "beyond doubt" his controversial pre-war claim that Iraq was capable of launching chemical and biological weapons within 45 minutes and said concern over Iraq's ambitions to develop weapons of mass destruction had been the main factor behind Britain's decision to back the war.
But he admitted Washington and London had different views, with the U.S. favoring regime change to overthrow Saddam Hussein as the main justification for war.
The 45-minute claim was made in Blair's preface to an intelligence document that came out in September 2002 and detailed the threat posed by Iraq. The document, Blair said, was "clear" in backing up the claim he made in the preface.
"If you go back to that time, if you read the executive summary and the information that follows, I can't see how you can come to a different conclusion," Blair said of evidence for the 45-minute claim.
British media quickly highlighted the claim and it filled the headlines of British newspapers the next day. But no significant caches of chemical or biological weapons have been found in Iraq since the invasion.
The former prime minister denied he had inserted the 45-minute claim to make the intelligence document seem more important.
Blair said he not only believed the claim was true, but he also worried about the possibility that it wasn't true -- and he had to act on that concern.
"Supposing we put it the other way around and it was correct, and I wasn't going to act on it. That was the thing that was worrying me," Blair said.
"Your worry is not simply, 'Is the intelligence correct so that I can act?'" he added. "Your worry is also if it is correct, what am I going to do about it?"
Earlier, Blair told the inquiry he had been "determined" to stand "shoulder to shoulder" with the U.S. despite their differing opinions over the reasons why war was necessary.
"The Americans, in a sense, were saying, 'We're for regime change 'cause we don't trust he's ever going to give up his WMD ambitions,'" Blair said.
"We were saying, 'We have to deal with his WMD ambitions. If that means regime change, so be it.'"
Blair said that the September 11, 2001, terrorist attacks on the U.S. had changed attitudes in both London and Washington towards how Saddam Hussein's regime should be handled.
"Up to September 11 we thought he was a risk, but we thought it was worth trying to contain it," Blair testified.
"The crucial thing after 9/11 is that the calculus of risk changed... After September 11, if you were a regime engaged in WMD (weapons of mass destruction), you had to stop."
Blair told the inquiry that he had considered the 9/11 attacks to be an attack on the UK as well as the U.S.
"I said I would stand shoulder to shoulder with them. We did that in Afghanistan, and I was determined to do that again" in Iraq, Blair said.
In an interview aired last month on the BBC, Blair sparked controversy by indicating he would have gone to war even if Saddam had been found to have no WMD, or weapons of mass destruction.
Blair said Friday that Iraqi citizens were "actually upbeat about the future" and said a "majority think security and services are getting better."
"It's too early to say right now whether the democracy will take root and function effectively," but there were "hopeful signs," he said.