Airport operator BAA must sell London Stansted airport in order to pave the way for better competition, according to a ruling by a British court on Wednesday.

The ruling is the latest twist in a long battle between BAA and the Competition Commission (CC), which stretches back to 2009 when it was ruled that the group exerted a dominant hold on British airports, especially in Scotland and the south-east of England.

Late last year the CC ordered BAA to sell one of its Scottish airports before it disposes of Stansted airport, which is located about 60 kilometres north-east of London.

BAA, owned by Spanish infrastructure group Ferrovial, put Edinburgh airport up for sale in October 2011, bowing to the watchdog's order but asked for a judicial review of the CC's ruling requiring it to sell off Stansted.

BAA's appeal over the Stansted sale was dismissed on Wednesday after a judicial review by the Competition Appeal Tribunal.

BAA owns London's Heathrow -- Europe's busiest airport -- as well as Southampton and Stansted in England and Glasgow, Edinburgh and Aberdeen airports in Scotland.

The airport operator sold London's Gatwick - the capital's second largest airport - to Global Infrastructure Partners for 1.5 billion pounds in 2009 as part of the CC's original ruling on Britain's airport market.

With Gatwick already sold BAA believes being forced to sell the other airports is unfair because the prevailing economic conditions mean they will not fetch a fair price and because the airports market in the south east of England has changed.

(Reporting by Rhys Jones; editing by Matt Scuffham)