A Spanish court has ruled that the pop star Julio Iglesias is the biological father of a 42-year-old man whose mother said she had a brief affair with the singer in the 1970s.

In a case that has dragged on for two years, a judge in Valencia ruled that Javier Sánchez Santos, who now lives in Italy, is the Spanish singer’s son despite Iglesias repeatedly refusing to give a DNA sample.

The judge’s decision was based on the testimony of María Edite, a former ballerina, who said she had a one-week affair with Iglesias in Sant Feliu de Guíxols on the Costa Brava in 1975 and that Santos was born as a result of that relationship.

The case had already been dismissed in 1992 but Santos’s lawyer, Fernando Osuna, insisted DNA evidence procured by a detective in the US was cause for the case to be reopened.

The detective managed to get hold of a water bottle that the singer’s son Julio Iglesias Jr was drinking from when he was surfing in Miami. Osuna claimed DNA testing showed that Santos and Iglesias Jr were brothers.

The judge refused to admit the DNA as evidence but in his ruling stated that “there is a clear physical resemblance between father and son” as well as the evidence that “at the time of conception there was a certain amount of contact between María Edite Santos and Julio Iglesias during which time it is not implausible that they had a sexual relationship”.

Iglesias, 75, who was not in court, has consistently denied he is the father and his lawyers say he will appeal against the decision.

The Grammy-winning singer, who has sold more than 300m albums over a long career, is probably Spain’s biggest international star and sang at the White House at Ronald Reagan’s Christmas party in 1983.

However, his love life has won him as much publicity as his music, and he has been keeping Spain’s sensationalist “pink press” in copy for decades. Santos aside, he has eight children, three from his relationship with Isabel Preysler, whom he married in 1971, and five more with his second wife, Miranda Rijnsburger.

Before the ruling, Preysler, who was Iglesias’s wife at the time of the alleged affair, said she believed that if it was proven that Santos was his son, Iglesias would “do his duty as a father because Julio has always been a very responsible person”.

Enrique, the third son of Preysler and Iglesias, is also a successful singer who has won five Latin Grammys.