The principle of "fraternity" should have shielded an olive farmer who was prosecuted for helping hundreds of migrants to enter France, one of the country's top courts has ruled.
Cedric Herrou received a four-month suspended prison sentence last August for taking migrants from the Italian border to his farmhouse in the Roya Valley in southeastern France. He housed them in a makeshift camp at a disused railway premises.
"The concept of fraternity confers the freedom to help others, for humanitarian purposes, without consideration for the legality of their stay on national territory," the constitutional court ruled.
Fraternity is one of three values that make up France's constitutionally enshrined national motto: Liberty, Equality and Fraternity.
The court said France's parliament should adapt the law and its ruling could reverberate across the European Union at a time of deep divisions within the bloc on how to deal with migrants.
Migrants who successfully cross the Mediterranean sea from Libya and elsewhere to Italy often go north and try and slip across the mountainous border into France. The country tightened its border controls in 2015.
Mr Herrou has said he believed he had a duty to provide food and shelter to desperate migrants fleeing war, poverty and oppression.
French law covering the entry of foreigners and right to asylum states that anyone aiding "the unlawful entry, movement, or stay of a foreigner in France" is liable to face up to five years in prison and a fine of up to €30,000 (£26,500).
However, it grants immunity to anyone who offers such help to a foreigner without receiving anything, such as money, in return. The court said the words "unlawful stay" should be removed to ensure that the principle of fraternity extends to those in France both legally and illegally.
In a statement, Interior Minister Gerard Collomb said the ruling was compatible with draft immigration and asylum legislation being debated in parliament.
The new law would double to 90 days the time in which illegal migrants can be detained, shortens deadlines to apply for asylum and makes the illegal crossing of borders an offence punishable by one year in jail and fines.
The centre-right party, The Republicans, said it saw "major problems" with the ruling.
"This is an ideological victory for those who consider that illegal immigration is legitimate ...and an encouragement for those who think France doesn't have the right to protect its borders," Guillaume Larrive and Eric Ciotti, two of the party's politicians, said.
Agencies contributed to this report
Join our commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies