The European Court of Justice (ECJ) has ruled that the Scottish Government's plan for a minimum alcohol price could breach EU law if less restrictive tax measures could be introduced.

Judges at the Luxembourg court concluded that the policy would restrict the market, which could be avoided by the introduction of an alternative tax measure designed to increase the price of alcohol.

They said it was ultimately for the national court of an EU state to determine whether other measures would be as effective in achieving the desired public health benefit.

Scotch Whisky Association (SWA) officials mounted a legal challenge alongside other European wine and spirits producers after legislation to introduce minimum pricing was passed by the Scottish Parliament in 2012.

The case will now be referred back to the Court of Session in Edinburgh for a final decision.

The SWA's legal challenge to the proposal of a minimum unit price of 50p was initially rejected by judge Lord Doherty at the Court of Session in 2013.

Following an appeal hearing, the case was referred to the ECJ last year for its opinion on six points of European law, with an interim opinion published in September.

In their ruling, judges concluded that a minimum price would constitute an obstacle to the free movement of goods, but that such a measure may be justified on health protection grounds "only if it is proportionate to the objective pursued".

The court said a fiscal measure increasing the taxation of alcoholic drinks "is liable to be less restrictive" than minimum pricing.

The Scottish Government does not have the power to raise taxes on alcohol, with this ability reserved to Westminster.

Welcoming the ruling, SWA chief executive David Frost said: "The court has confirmed that minimum unit pricing (MUP) is a restriction on trade, and that it is illegal to choose MUP where there are less restrictive ways of achieving the same end.

"The Scottish courts will now reflect on the implications of the ruling and all the evidence, before issuing a final judgment.

"This ruling opens the way to moving the debate on and allowing us to address alcohol misuse with practical measures that actually work. Alcohol-related deaths have fallen by a third over the last decade in Scotland, which suggests we are already on the right path.

"We remain committed to working closely with the Scottish Government and everyone else with an interest."

Scotland's First Minister Nicola Sturgeon tweeted: "ECJ opinion on minimum pricing welcome.

"We believe it is most effective way of tackling alcohol misuse. National court will now decide."

Alison Douglas, chief executive of health charity Alcohol Focus Scotland, said: "The ECJ has confirmed that Scotland can use minimum unit pricing to reduce our high levels of alcohol harm, provided it is more effective than taxation.

"Alcohol taxes are limited in their ability to raise the price of the cheapest alcohol to a level that will actually reduce harm, whereas minimum pricing is a targeted measure which will make the cheapest, strongest products less affordable to heavy drinkers who are most at risk of harming themselves and others.

"Moderate drinkers will barely notice any difference to the price they pay."

She said the policy had won support from health professionals, police and charities as it would "reduce hospital admissions, cut crime and save lives".

Ms Douglas added: "In taking legal action against the Scottish Government, the Scotch Whisky Association has blocked the democratic will of the Scottish Parliament and sacrificed public health to protect their members' profits."

Dr Peter Bennie, chair of British Medical Association (BMA) Scotland, said: "The case for minimum unit pricing has always been based on the fact that it achieves what taxation cannot when it comes to reducing the harm caused by alcohol, so the decision of the European Court setting out the test that must be applied to the policy is a welcome one.

"Today's ruling returns the case to the Scottish courts and puts Scotland a step closer to implementing minimum pricing.

"Every year of delay carries with it a human cost in lives lost and health damaged. Last year saw an increase in both the volume of alcohol sales and the number of alcohol related deaths.

"The need to implement minimum pricing remains as pressing as ever and those who have sought to delay it in the courts have failed to act in the public interest."