The judge ruled that 33-year-old Mesale Tolu, who was initially detained in late April, would be released with the other five remaining detainees in the case, the Law Office of the Oppressed, which is representing her, announced on Twitter.
The ruling came after a prosecutor requested at the start of Monday's hearing that Tolu and the five others be set free.
Tolu is charged with membership in the Marxist-Leninist Communist Party (MLKP), which is banned in Turkey as a terror group.
“She was ordered to be released under judicial control,” her lawyer Kader Tonc told AFP.
That means she should walk free from prison later Monday after completing the formalities, but she remains charged and on trial. Tolu will have to report to the authorities every week and cannot leave the country.
“We welcome this with joy and relief, even if the proceedings against her are not over,” said German foreign ministry spokeswoman Maria Adebahr. “It's a first step.”
Her case was one of many thorny issues that have stoked tensions between NATO allies Turkey and Germany over recent months.
'Good news but…'
German Chancellor Angela Merkel said it was not totally good news because Tolu remained charged under the terms of her release.
“On the one hand it's good news as she will be freed. But on the other hand it's not completely good news because she cannot leave the country and because the trial is ongoing,” the chancellor said.
Her spokesman Steffen Seibert said: “It's too early to make conclusions on how relations between Germany and Turkey will evolve.”
Tolu, who worked as a reporter and translator for the leftwing ETHA news agency, told the Istanbul court that she was detained as part a crackdown on freedom of press in Turkey.
“A fair verdict to be delivered by the judiciary will ease the conscience of the public opinion,” she said at the hearing.
Tolu had initially been in jail together with her three-year-old son. Her husband Suat Corlu, who was also jailed on terrorism charges, was released in late November.
Tolu is one of several German nationals detained under the state of emergency laws imposed in Turkey after the failed coup attempt last year, in a crackdown Berlin has criticized as excessive.
After the latest release, eight Germans remain behind bars in Turkey, including most prominently the Die Welt newspaper correspondent Deniz Yucel, who was arrested in February.
Berlin says Yucel and others are being held for political reasons.
The arrests prompted Germany, which is home to a large Turkish minority, to announce a full review of relations and to sharpen its travel advisory.
President Recep Tayyip Erdogan, for his part, has accused Berlin of sheltering plotters of the coup attempt, as well as Kurdish militants, and demanded their extradition.
In October, the court ruled to keep Tolu and five others behind bars, while eight were released pending trial.