Millions of pounds in taxpayers' money is being paid in compensation and legal fees to more than 900 prisoners who endured degrading conditions in Scottish jails.

In the first payout since a key House of Lords ruling in October last year, 927 prisoners who were forced to share a cell and slop out have been offered £2100 each. Their lawyers will receive £1900 for each case, bringing the total payout to £3.7m.

To curb the growing legal fees, officials have now said other affected prisoners can now simply write in to ask for the compensation and do not require legal representation.

Most prisoners have accepted the offer, although a handful have decided to continue their legal actions through the courts.

There are also ongoing cases from those who were forced to slop out or suffer other conditions but who did not share cells.

Slopping-out compensation claims were first raised in May 2001. Robert Napier, while in Barlinnie Prison for 42 days on remand, successfully claimed slopping out was "inhumane and degrading" and in contravention of Article 3 of the European Convention on Human Rights. The Scottish Executive lost the appeal and he was awarded £2450.

More than a year ago, some 190 prisoners, whose cases had been brought within the previous one-year time limit, were paid compensation costing the taxpayer £500,000.

The new offers follow October's House of Lords ruling that no specific time bar should be placed on the lodging of cases.