Put forward by First Minister of Scotland Jack McConnell, the plan was backed by ministers at a Cabinet meeting this month.
The Scottish Executive wants legislation to be introduced by Christmas and be implemented in bars, restaurants and other enclosed spaces by the spring of 2006.
Persistent smokers will face a maximum fine of £1,000 while licensees or employers could be fined up to £2,500 for ignoring the new law. The decision comes eight months after Ireland became the first country in the world to ban smoking in restaurants and pubs.
Because the legislation refers to public workplaces, the law includes company cars if they are registered in Ireland.