The number of patients kept in hospital after they are medically fit to go home will only grow if further cuts are made to public spending, opposition parties have warned.

A census carried out in October found 1576 people were delayed in their discharge, up from 1524 in September.

Over the course of October, patients spent 43,919 days in hospital as a result of delayed discharge.

Most delays were caused by health and social care challenges, such as an absence of care home places or social care support at home.

Finance secretary Derek Mackay will report on the Scottish Government's spending plans for 2017 on Thursday.

Labour health spokesman Anas Sarwar said: "The SNP promised to abolish delayed discharge, instead it is getting worse month on month.

"Further cuts to local councils which provide social care will only make this worse and it shows the complete mismanagement of our NHS under the SNP."

Scottish Greens' health spokeswoman Alison Johnstone said: "The number of people experiencing delayed discharge is likely to rise unless we do much more to prioritise social care support at home, the availability of care home places and social care staff.

"Our discussions with the government about the 2017 Scottish budget will include Green proposals for ensuring that more resources go into social care."

Scottish Liberal Democrat health spokesman Alex Cole-Hamilton said: "All parties supported the bringing together of NHS and local council care services but these figures raise questions about the difference this is making at this early stage.

"The Scottish Government must immediately set out how they will be supported to speed up the process so people aren't spending months on end in hospital for no good reason."

Health secretary Shona Robison said: "One unnecessary delay is one too many and I've made clear my ambition and expectation that our new integrated health and social care partnerships will successfully address this.

"We're working with boards to prepare for winter and recently announced £3m in November to support them.

"This is in addition to the £30m a year allocated to health and social care partnerships to help them tackle delayed discharges."

She added: "We know that reducing the number of people inappropriately delayed helps to ensure hospitals have sufficient capacity.

"We fully expect that to happen over the coming months and will continue to work with those facing the most significant challenges."