All Scots men convicted of crimes relating to homosexual activity are to receive an "automatic" pardon and have their records wiped, justice secretary Michael Matheson announced today.
The move was hailed as a "historic" at Holyrood and goes further than a similar measure unveiled by UK ministers last week.
Mr Matheson told MSPs today that there are men in Scotland who still have convictions for same-sex sexual activity which only became lawful north of the border in 1980.
"We must right this wrong," he said.
"We will introduce an automatic pardon for people convicted so that they know they are absolved fully of that conviction.
"We want to address the injustice that people experience simply because of their sexual orientation in circumstances that are now legal.
"The granting of an automatic pardon is one way of achieving this."
This goes further than measures announced at Westminster last when the UK Government announced that it would allow such pardon, but those convicted would have to apply for them.
Mr Matheson also said information held on record about such convictions north of the border by Police Scotland will also be wiped clean, so they don't affect men facing disclosure checks.
Labour leader Kezia Dugdale welcomed the pardons.
She said: "That is a hugely welcome announcement - in fact it is nothing short of a historic moment for Scotland to be a more equal and respectful country."
She also called on ministers to issue a public apology for the actions of the state in imposing such convictions. Mr Matheson agreed to consider this.