The custody battle began in 2012 when the mother was forced to leave Turin after her family, and the father of her child, refused to accept her choice of a female partner.
The couple moved to a small town in the south of Italy, taking the daughter with them, a move which prompted the father to begin a custody battle.
The father, who had to stop paying child support for a few months because of financial strife, argued that the child was being raised in an unnatural environment - an argument that was rejected by the judge.
Citing a ruling by Italy's top court in 2012, the judge said: "Complaints that a model family cannot be made up of people of the same sex are not based on scientific nor experiential data.”
The ruling comes as the gay rights movement gathers speed in Italy, and its importance was underscored by the mother's lawyer, Alessandro Vaccaneo.
“It's one of the first clear-cut rulings of of its kind in Italy,” he told La Stampa.
The child's mother declared herself pleased at the result by declaring, “It's love that makes a family.”
Data on children raised by same sex couples is elusive. However, a few days ago the child's mother posted a photo of her daughter's report card on Facebook.
“Here's my daughter's report card,” she wrote. “I'm proud of her progress, behavior, manners and desire to learn.”
“This is a girl who has been raised by two women for almost three years. For anyone who thinks a non-traditional family is traumatic we're sorry - for us it is a great joy.”
According to the ruling, the father will be able to see his daughter one weekend a month, half of the Christmas holidays, the entire Easter holidays and for three weeks during the summer.
The right to appeal was rejected, and the father was told to pay the legal fees the mother had incurred.
His lawyer, Arianna Scavone, argued that he had been "marginalized".
“The problem is not that it's two people of the same sex, but that the father has been marginalized, creating an unrealistic situation.
“Biologically, you can't have two mothers and two women can't marry in Italy, at least not yet.”