Canada is to become only the second country to have a legal nationwide cannabis market after a landmark government bill was passed by the senate.
The Cannabis Act sailed through by a vote of 52 to 29 on Tuesday, allowing for the drug to become available for recreational use as soon as the cabinet decides on a final date.
It is expected to be decided upon by mid-September, meaning retail sales could begin before the end of the year.
Until now, only Uruguay had made the cultivation, distribution and consumption of marijuana legal, with the government there having sought to wrest the business from criminals.
Prime Minister Justin Trudeau is hoping legalising the drug will have a similarly positive impact in Canada, where marijuana can already be used for medicinal purposes.
“It’s been too easy for our kids to get marijuana – and for criminals to reap the profits,” he said on Twitter.
“Today, we change that. Our plan to legalise and regulate marijuana just passed the Senate. #PromiseKept.”
Mr Trudeau had hoped to make cannabis available at retail by 1 July, but provincial and territorial governments need eight to 12 weeks from senate passage to prepare.
Once sales get up and running, Canada will become the first G7 industrialised country to have a legal nationwide cannabis market.
In the US, it is only allowed in the states of Colorado, Washington, Oregon, Alaska, California, Massachusetts, Maine and Nevada.
Other countries, including Australia, Germany and Norway, only allow it to be used for medicinal purposes, while in many parts of the world it is entirely illegal.
The successful vote came on the same day that former Conservative leader Lord Hague suggested the UK should also legalise cannabis.
Writing in The Daily Telegraph, he said the eventual approval by the Home Office for medicinal cannabis oil to be used to treat epileptic youngster Billy Caldwell was evidence that a hard-line stance on the drug had become “inappropriate, ineffective and utterly out of date”.
He said it was time for the government to “embrace a decisive change”, adding: “Can British Conservatives be as bold as Canadian Liberals? We ought to be.”
While a Sky Data poll has found most Britons agree that cannabis should be made legal for medicinal purposes, it is a far more even split when it comes to recreational use – with 41% in favour and 40% against.
Home Secretary Sajid Javid has declared it is “time to review” the medicinal status of cannabis, but promised it is “not a first step” to legalising the drug for recreational use.
An expert panel is being set up to advise ministers of potential changes to the law in the UK, which is the world’s largest exporter of legal cannabis.
Currently, those found in possession without a licence face up to five years in prison, an unlimited fine, or both.
Supply and production also result in up to 14 years in prison and an unlimited fine.