An Italian judge ruled on Tuesday that the German captain of a rescue charity ship had not broken the law when she forced a naval blockade at the weekend, saying she had been carrying out her duty to protect human life.

Carola Rackete, a 31-year-old German national, disobeyed Italian military orders and entered the port of Lampedusa on Saturday to bring some 41 African migrants to land in the Dutch-flagged Sea-Watch boat.

She was immediately detained and placed under house arrest, but in a blow for Italy's hardline interior minister, Matteo Salvini, Judge Alessandra Vella ruled that Rackete had been carrying out her duty and had not committed any act of violence.

Rackete still faces possible charges of helping illegal immigration, but Vella ordered her immediate release.

Salvini said in a statement he had hoped for a tougher response from the Italian justice system and promised to expel Rackete as soon as possible.

The controversy over Rackete's actions have dented relations between Italy on the one side and Germany and France on the other, and have highlighted Europe's continued failure to adopt coherent immigration norms.

Rackete appeared before the Agrigento court on Monday and apologised for hitting the patrol boat, saying it had been an accident and explaining that her sole concern was the well-being of the migrants who had been at sea for more than two weeks.

Read more: Rescue ship captain Carola Rackete defends herself after Italy arrest

Want more news?