A ban on smoking in bars, restaurants and all public places has been approved by MSPs at Holyrood.
Scotland's smoking ban is due to come into effect in 2006
The Smoking, Health and Social Care (Scotland) Bill will come into force on 26 March 2006.
Health Minister Andy Kerr said the ban would help smokers give up and protect other people from passive smoking.
The ban was approved by 97 votes to 17 with only the Conservatives opposed. Their attempts to exempt theatre stages and specialist tobacco shops failed.
Employers failing to enforce the ban will face fines of up to £2,500 and those caught smoking could be hit with penalties of up to £1,000.
Smokers could be fined for lighting up in a pub, a restaurant, an office, a theatre, a bingo hall or even a public toilet.
Exemptions include prison cells and residential care centres.
Other measures in the bill include free eye and dental checks, a key Liberal Democrat demand, and authorised payments for those who contracted Hepatitis C from NHS blood products.
Mr Kerr said that it was the most important piece of public health legislation in a generation.
He said: "It shows how Scotland can lead the UK. A tribute to the success of devolution.
"We have been congratulated for going further than the measures that have been proposed for England, but Scotland's problem is far greater - higher numbers of smokers leading to higher risks for public health."
The minister added: "This is a proud day for many people and I am personally proud to be a part of it on this historic day in the Scottish Parliament."
The Scottish National Party health spokeswoman Shona Robison said: "To ban smoking in enclosed public places will have an immediate benefit for those who work in pubs, restaurants and other enclosed public places and those who visit those establishments.
"Importantly, it will also have a longer term benefit because it does
de-normalise cigarette smoking."
Conservative health spokeswoman Dr Nanette Milne told MSPs: "We are disappointed the executive has not taken a more reasoned approach."
She said there had been big advances in smoke-free provision in recent years.
And ventilation systems bring down smoke pollution to "acceptable" levels.
"If air quality can be shown to be acceptable, there is no reason why there should not be more exemptions for the smoking ban," she said.
And she told parliament: "We have serious concerns this legislation will lead to displacement of smoking to the home, with increased exposure of children to a smoke-filled atmosphere and a potential increase in home consumption of alcohol."
She said smoking was still legal and declared: "There has to be some choice for smokers as well as non-smokers."
But Nora Radcliffe, for the Liberal Democrats, hailed the bill with
"enthusiasm" and said it was a major delivery of her party's policy.
"The Scottish Liberal Democrats were the first party in Scotland to support a ban on smoking in public places," she said.
"The UK Government accepts they will eventually have to go for a
comprehensive ban rather than the messy compromise they are wrestling with."
The BMA in Scotland welcomed the Scottish Parliament's decision.
Chairman Dr Peter Terry said: "This landmark legislation benefits the health of each and every Scot, who will shortly be protected from the devastating effects of second hand tobacco smoke.
"We congratulate parliament for delivering the clear message that second hand tobacco smoke kills and that the entire population has the right to be protected from it."
Cancer Research UK added that the decision marked "an historic day for Scotland".
Chief Executive Professor Alex Markham said: "Scotland is leading the way in the UK by adopting smoke-free legislation that will protect thousands of workers.
"There is little doubt that making all workplaces and enclosed public places smoke free will bring about some of the most significant health improvements Scotland has seen in decades."