Judges at the Court of Session in Edinburgh today found that the measure, which is aimed at targeting cheap alcohol and lagers, protects "life and health" in a way that other measures cannot.
They found that the proposed 50p per unit will "reduce consumption amongst harmful and hazardous drinkers" whose health is affected most by the consumption of cheap alcohol.
"The benefits of this are well documented," its judgement states..
"It is reasonable to conclude that alternative measures, including increases in taxation, are not capable of protecting life and health as effectively as minimum pricing, while being less restrictive of trade."
The legal challenge had been brought by Scotch Whisky Association and wine makers under European law and comes after advice was sought on the issue from EU courts.
The 50p per unit proposed by ministers would mean a bottle of spirits would cost at least £14 and cheap, strong cider could double in price.
The Scottish government, health professionals, police, alcohol charities and some members of the drinks industry believe minimum pricing would help address Scotland's "unhealthy relationship with drink".