After 107 days of incarceration, Sarah Mardini – the Syrian human rights worker who saved 18 refugees in 2015 by swimming their waterlogged dinghy to the shores of Lesbos with her Olympian sister – has been freed from Greece’s toughest jail.

The 23-year-old was released late on Wednesday from the high-security Koryallos prison in Athens, where she was being held in pre-trial detention on charges of people-smuggling.

She was allowed to walk free after her lawyers posted €5,000 (£4,450) in bail.

Sean Binder, a 24-year-old volunteer born in Germany and resident in Ireland, was also freed from custody in Chios along with two others from the NGO for which both had worked.

“We are all incredibly happy, incredibly relieved,” said Dr Florian Becker, the managing director of Bard College in Berlin, where Mardini had been enrolled before her arrest in Lesbos in August. “But sadly this is not the end. While copious evidence has been produced to prove their innocence we still don’t know if the charges will be dropped against them.”

Greece was strongly criticised by human rights groups following the aid workers’ arrests. Amnesty International and other organisations insisted the case embodied efforts to criminalise humanitarian work in a climate that has become increasingly hostile towards migrants and refugees across Europe.

Mardini and Binder had faced prison sentences of up to 25 years after being accused of facilitating people-smuggling through membership of a criminal organisation. Charges of espionage and money laundering were also levelled at the activists. Both had been volunteering in search and rescue operations with the now-defunct Emergency Response Centre International (ERCI), an NGO based on Lesbos.

In an unusually long statement following six months of inquiries, police said the activities amounted to “organised migrant trafficking rings” by people who had knowledge of “specific refugee flows”.

Zaccharias Kesses, the lawyer heading the aid workers’ legal team in Athens, confirmed that Mardini would be free to return to Berlin, where her supporters have taken to the streets.

Previously a judge had rejected appeals for the aid workers to be released, citing the risk of re-offending.

“The release of all of them at the same time is proof that there is not enough evidence against them,” Kesses told the Guardian. “The arrests were clearly part of an organised plan to criminalise humanitarian aid and to a great degree it worked. Hundreds of volunteers have been discouraged and on Lesbos many have left. Their release today is a great success.”

But Kesses said a trial was still likely to take place. “The charges may be amended but I think it very unlikely that the trial will be dropped. There is vast pressure in local society against NGOs, who are perceived to be pull factors for refugees at a time when few want them.”

Although arrivals on Greek shores have abated since the peak of the migrant crisis at the height of Syria’s civil war, the influx has increased this year with growing numbers dying or being reported missing while attempting to reach Greece from Turkey in rickety boats crossing the Aegean Sea.

Amnesty International’s Greece researcher Kondylia Gougou said: “Whilst we welcome the news that these dedicated humanitarians will be back with their families tonight after more than 100 days behind bars, the fact that they still face absurd charges and potentially long prison sentences is an outrage. To detain dedicated volunteer humanitarians who helped people in need defies logic … these baseless charges should be dropped.”