London (CNN) -- It's been a long journey for Richard III, the 15th century king whose skeleton was found under a parking lot in the English city of Leicester. But on Friday, his final destination became clear.
The medieval monarch will be reburied in Leicester Cathedral, just a stone's throw away from where his remains were uncovered.
The discovery of his remains, complete with curved spine and staved-in skull, in the summer of 2012 sparked global headlines and a new battle -- over which city would host his remains in perpetuity.
Archaeologists had been searching the site for Leicester's long-lost Greyfriars Friaryhad and always planned for any bodies they uncovered to be reburied at the city's cathedral.
That was challenged in the courts by a group calling itself the Plantagenet Alliance, which argued it was the medieval king's wish to be buried in the historic northern city of York -- the city they claim was closest to his heart.
But judges at the Royal Courts of Justice ruled Friday that his funeral should be held in Leicester as originally planned.
Their ruling notes that since Richard's exhumation, "passions have been roused and much ink has been spilt" as rival camps fought to stake their claim.
Now, they say, "We agree that it is time for Richard III to be given a dignified reburial, and finally laid to rest."
The University of Leicester, which was behind the excavation project, celebrated the outcome on Twitter.
"Richard III will be reinterred in Leicester. Great news for the University, our city and everybody involved in the discovery," it said.
In bringing its case, the Alliance objected to the lack of consultation over where the newly-rediscovered monarch's bones should be laid to rest, saying more thought should have been given to the question.
On its website, the Alliance -- made up of people who claim to be distantly related to Richard III, and headed by Stephen Nicolay, his 16th great nephew -- set out its argument to have him reburied in York.
"We believe that the proposed location of Leicester is wholly inappropriate for the burial of King Richard III, who had no connections with the town beyond his horrific death, bodily despoliation and appalling burial in a foreshortened grave," it said.
"As people who have died in a foreign place are 'brought home,' so too King Richard should be brought to a place with which he had every possible connection and affection."
Richard III lost his life in the Battle of Bosworth in 1485 -- the last king of England to die on the battlefield and the last monarch from the House of York.
Until his remains were found, the monarch was best known to modern Britons as the hunchbacked Shakespearean villain accused of murdering his nephews, the "Princes in the Tower," to usurp the throne.
That notorious history may make the battle over his reburial site appear all the more unlikely. But both sides insisted they have a strong claim to his remains.
Now Leicester could see a significant commercial benefit, if tourists flock to see his final resting place.
The city already has plans for a new tomb in the cathedral, where a memorial stone has long paid tribute to the last Plantagenet king, and for a visitor center on the site of the Greyfriars car park, telling the story of Richard's life, his death, and his rediscovery.
In a statement, Leicester City Mayor Peter Soulsby said: "I am delighted that Leicester Cathedral can now proceed with its plans to give King Richard lll a dignified reburial here in the city.
"With the support of the city council and the University of Leicester, the cathedral is now planning for the king's reinterment to take place in the spring of next year."
CNN's Bryony Jones contributed to this report.