Facebook has lost a crucial legal battle in France as a court ruled the social network can be sued over its decision to remove the account of a user who posted a photo of a famous 19th-century nude painting.

The ruling by the Paris appeals court could set a legal precedent in France, where Facebook has more than 30 million regular users. An appeal could go to the country's highest court.

It means a French court can hear the case of a 57-year-old Parisian teacher and art lover, whose Facebook account was suspended five years ago without prior notice.

That was the day he posted a photo of Gustave Courbet's 1866 The Origin of the World, which depicts female genitalia.

He wants his account reactivated and is asking for €20,000 in damages.

Facebook has not given an explanation for the suspension of the account. Its lawyers had argued that such lawsuits could only be heard by a specific court in California where it has its headquarters, and that French consumer rights law cannot apply to users in France because its worldwide service is free.

A Paris appeals court dismissed those arguments and upheld a lower court's decision that ruled French courts can hear cases involving users in France.

The appeals court said a small clause in Facebook's terms and conditions requiring any worldwide lawsuits to be heard by the Santa Clara court is "unfair" and excessive. The judges also said the terms and conditions contract signed by any user before creating a Facebook account does fall under consumer rights law in France.

"This is a great satisfaction and a great victory after five years of legal action," said lawyer Stephane Cottineau, who represents the teacher. He said it sends a message to all "web giants that they will have now to answer for their possible faults in French courts".

"On one hand, Facebook shows a total permissiveness regarding violence and ideas conveyed on the social network. And on the other hand, shows an extreme prudishness regarding the body and nudity."

The French government has lobbied Silicon Valley tech giants to take down violent extremist material, notably after deadly attacks in Paris last year.

Sign up to our free newsletters

Get the best updates straight to your inbox:
Please select at least one mailing list.

You can unsubscribe at any time by clicking the link in the footer of our emails. We use Mailchimp as our marketing platform. By subscribing, you acknowledge that your information will be transferred to Mailchimp for processing.