The High Court has declared lawyer Miguna Miguna's deportation illegal.
Judge Luka Kimaru ruled on Thursday that the declaration by Interior minister Fred Matiang'i was null and void.
He directed Immigration director Gordon Kihalagwa to surrender Miguna's passports to court within seven days.
The government forced the National Resistance Movement 'general' to Canada after he participated in Nasa leader Raila Odinga's swearing-in at Nairobi's Uhuru Park on January 30.
Miguna was with Ruaraka MP Tom Kajwang and Siaya Senator James Orengo, who has represented many of the coalition's politicians in legal matters.
The lawyer said from Canada that he would be back and noted that his Kenyan citizenship cannot be revoked as he was born in the country.
He said police should have taken him to the courts as judges ordered instead of seizing his passports and driving him to the JKIA.
KImaru earlier ordered Kihalangwa to swear and file affidavits explaining circumstances under which Miguna was deported.
The judge said the the senior government officer should explain how he took custody of Miguna when he knew very well that there were clear instructions requiring the lawyer to be produced in court.