Alan MacSporran, a lawyer acting on behalf of the Commonwealth Director of Public Prosecutions (DPP), said that the DPP's review revealed two errors. "As a result of this review the director has decided that there is no reasonable prospect of a conviction in this case."
Haneef was arrested at Brisbane airport on July 2, two days after British police foiled a series of terrorist attacks in London and Glasgow.
He was charged 12 days later with providing support to a terrorist organisation by giving his mobile phone SIM card to a relative later charged over the attacks.
Information relating to the SIM card was one of two mistakes admitted by the DPP.
DPP prosecutors told the Brisbane court the first error related to the location of the SIM card, which was first claimed to be found in a burning jeep used in the Glasgow terror attack.
It was later revealed that the SIM card was in possession of Haneef's cousin in Liverpool, more than 300km away.
The second error related to where Haneef was living in the UK "and was based on incorrect material provided by the Australian Federal Police (AFP), visa, it was conceded.
Kevin Andrews, the Minister for Immigration, who two weeks ago thwarted a magistrates decision to release Dr Haneef into the community by cancelling his visa, said he had decided to free the doctor into residential detention while advice was sought on the implications of the dropping of charges.
"That means that rather than being detained in immigration custody, namely in Villawood or some facility such as that, he will be released into residential detention which means that he can reside at his unit on the Gold Coast," Andrews told reporters.
"Or if he wishes to reside somewhere other than that unit on the Gold Coast, then any reasonable request in that regard will be taken into account and met."
Andrews also said he would seek further advice from the commonwealth solicitor-general about whether he would need to reverse his decision to cancel Haneef's visa.
"I am taking the precaution of seeking the advice from the highest law officer in the commonwealth, namely the solicitor-general, as to whether or not there are any implications for my (visa) decision," Andrews said.
"I have to act according to my responsibilities under the migration legislation.
"My decision, at the moment, stands."
Haneef was accompanied by immigration officials when he left the correctional centre in a blue van in the middle of a three-vehicle convoy.
Haneef's solicitor Peter Russo said he had "no idea" where his client would be taken.
Haneef lived in a Southport apartment until before being charged but the unit manager said his lease expired on Wednesday due to rental arrears.
"He's officially no longer a tenant here," the Gold Coast apartment manager, Steve Boscher, said.
He noted that the unit was "uninhabitable" after damage caused by two police searches.
"The unit is still being cleaned and needs to be repainted and recarpeted," he said.
Boscher said Haneef's belongings from the Gold Coast unit had been placed in storage.
Haneef's solicitor Peter Russo said he would fight any move by Andrews to have his client deported.
Russo has lodged an appeal against the decision to cancel the visa in the Federal Court and said the August 8 hearing of the case would go ahead.
Mick Keelty, the AFP Commissioner, said that the police would continue to investigate any potential Australian links to the failed UK terror attacks.
Keelty said he stood by his advice to Andrews which was used to cancel Dr Haneef's visa.
"The grounds of which the AFP provided advice to the minister for immigration have not changed," he said.
Keelty would not say whether he wanted Dr Haneef to remain in the country while the AFP investigation continued.
"It's a matter for the immigration minister and it's a matter for the attorney-general as to what steps are taken as to whether Dr Haneef remains in the country or whether he leaves," he said. But he said Haneef's arrest and charge could have been avoided had the doctor not tried to return to India.
"The steps that we've taken right from day one in terms of detention were initiated as a result of Dr Haneef attempting to leave the country," Keelty said.
"Had that not occurred, other steps might have followed that would have been quite different."
Meanwhile, Queensland Premier Peter Beattie says Dr Haneef is welcome to return to his job at the Gold Coast Hospital - if the federal government restores his work visa.
"With regard to Dr Haneef's employment, he is currently suspended from duties at the Gold Coast Hospital," Mr Beattie said.
"If the Howard government now allows Dr Haneef to keep his work visa, then Queensland Health would welcome him back as an employee at the Gold Coast Hospital.
"Should Dr Haneef wish to resume his employment at the Gold Coast Hospital, then the local district manager will meet with him to make those arrangements.
Meanwhile, Prime Minister John Howard has distanced his government from the dramatic collapse of the terrorism case against Indian doctor Mohamed Haneef.
Howard said it was up to AFP Commissioner Mick Keelty and federal Director of Public Prosecutions Damian Bugg, to explain what had happened.
"Bearing in mind that the detention of the man was undertaken by the police, and not at the request or direction or encouragement of the government, and the case was prepared and presented by the DPP, I think that the right thing now is for those two men to explain the process, and explain the reasons," he told reporters in Bali.
"Prime ministers don't conduct prosecutions, nor do attorneys-general - directors of public prosecutions do."
But others felt the fiasco could be attributed to political pressures on the police, mounted with an eye on the forthcoming national elections.
Australian Greens leader Bob Brown says the handling of Haneef's case has damaged Australia's international reputation.
Senator Brown says the Greens will be pushing for a Senate inquiry.
"You can't move beyond thinking that the mistakes here come out of the politicians in the Howard Cabinet wanting to put fear into the Australian public as a means of changing votes," he said.