Malaysian opposition leader Anwar Ibrahim, who was arrested over sodomy accusations, has been released from police custody after being granted bail, his lawyer said on Thursday.
"He is freed, he is not feeling well and he's going straight home," lawyer Sankara Nair said.
He was expected shortly to leave police headquarters where he was taken after his arrest on Wednesday and spent a night in detention.
Sankara had earlier expressed doubt that Anwar would be released, accusing police of reneging on a promise to free him on Wednesday evening.
Anwar has said the allegations made by Mohamad Saiful Bukhari Azlan, a 23-year-old former aide, are a government conspiracy to prevent him from seizing power after March elections where the opposition made major gains.
His party said that 20 balaclava-clad police commandos swooped on the opposition leader's vehicle as he approached his home on Wednesday, just an hour before he was due to appear voluntarily for a police interview.
He was taken to Kuala Lumpur police headquarters and underwent a long interrogation before being taken to hospital for a medical examination, where his lawyers said he refused to give a DNA sample.
Police are allowed to hold Anwar for 24 hours but then must either charge him or apply for a court order to extend his detention for up to 14 days.