Police have released the final man being held for questioning over an alleged terrorist conspiracy to bring down passenger planes flying from Sydney to the Middle East.

Khaled Merhi, 39, was released from police custody on Sunday afternoon, after being charged with possessing a prohibited weapon.

He was driven away from Surry Hills police station about 4.30pm, just hours before a special order to hold him for seven days for questioning expired.

Mr Merhi will face court later this month.