The woman, Maria Pilar Abel Martínez, who was born in 1956, claims the painter had an affair with her mother in 1955, according to BBC.
“The DNA study of the painter’s corpse is necessary due to the lack of other biological or personal remains with which to perform the comparative study," the Madrid court said, according to the Guardian.
There is no date set for the exhumation, but it could happen as early as July, according to Martínez's lawyer, the BBC reported.
Dalí died in Spain in 1989 at the age of 85. He was buried in his hometown of Figueres, Spain at the Dalí Theatre and Museum. He had no known children while he was alive.
Martínez's mother Antonia was a maid who had worked for a family in Cadaqués, Spain, where Dalí had a home, the BBC reported. The woman said her mother often told her Dalí was her father — oftentimes in front of large groups of people. Martínez first publicly made the claim that Dalí was her father in 2015.
Martínez went under two paternity tests in 2007 but did not receive results, the BBC reported.
Dalí was married to Gala Dalí at the time of the alleged affair.
A representative from the Dalí Foundation did not respond immediately to request for comment.