The judges' ruling obliges Germany to review its custody laws
The German government says it will reform its custody laws after the European Court of Human Rights said a German man had suffered discrimination.
The Strasbourg court ruled that German courts were wrong to reject the unmarried father's plea to have joint custody of his daughter, 14.
Under current German law, single fathers can only get joint custody if the mother gives her consent.
Germany's justice minister says the custody law now needs changing.
Sabine Leutheusser-Schnarrenberger said there were plenty of cases where unmarried fathers "want to take responsibility for the child without entering into a power struggle with the mother".
She told Germany's
newspaper that the law ought to "take more account of the father's interests".
The court found that there had been a violation of Article 14 of the European Convention on Human Rights - prohibition of discrimination, and of Article Eight - the right to respect for family life.
The case in Strasbourg was brought by 45-year-old Horst Zaunegger in 2004, after he had battled unsuccessfully with German courts to get joint custody.
His daughter, born in 1995, grew up with both parents until their separation in 1998. Then she lived with her father until January 2001, when she went to live with her mother.
European Court judgments are binding on states that have signed the rights convention, meaning that they have to adjust their laws if a rights violation is exposed.