THE First Minister will apologise today on behalf of the Scottish Government to all men convicted of now-abolished sexual offences.

Nicola Sturgeon will make the apology at Holyrood to coincide with the publication of new legislation to provide an automatic pardon to all those convicted prior to 2001 under discriminatory laws.

The legislation was promised by Sturgeon when she presented her programme for government in September.

It will enable people to apply to have such convictions removed from central criminal conviction records.

A Scottish Government spokesman previously said the move would "right a historic wrong and give justice to those who found themselves unjustly criminalised simply because of who they loved".

The apology and the bill were welcomed by the Equality Network last month.

Former Scottish Labour leader Kezia Dugdale said the pardon "is about writing a wrong of the past".

She told BBC Scotland's Good Morning Scotland programme: "Nicola Sturgeon is today going to apologise on behalf of previous governments, other governments, and that takes a very big heart to do.

"It's very welcome because it's only when we are at peace with our past, can we really focus on ensuring that for the future Scotland is an open and welcome place for LGBT people."

She added: "The reality is that sex between two men was only decriminalised in 1980 and the laws around sexual acts were only equalised in 2001 so this is the past but it is the fairly recent past.

"There are people alive today who have got very sore and very long memories about how they have been treated and this apology is for them, the pardon is for them."

Stonewall Scotland director Colin Macfarlane said: "The First Minister's apology today is an important moment, both for the LGBT community and for Scotland.

"Gay and bi men in Scotland were criminalised for a very long time simply for who they were and who they loved.

"Today's apology will give a great deal of comfort to many who were unjustly prosecuted, and will help draw a line, once and for all, under a dark period in Scotland's history.

"As well as the hurt and damage that came with being prosecuted for these crimes, many men have carried a criminal record with them their whole lives as a result. We're very pleased to see that this Bill includes provision for these unjust convictions to be wiped from criminal records, and a pardon, both for those living and deceased."