The number of applications to detain people with mental health issues, dementia or learning difficulties for their own safety has reached the highest level on record.

Meanwhile, thousands of applications have taken more than a year to be completed - despite the recommended time-frame of just three weeks.

In some circumstances, patients who lack the mental capacity to consent need to be detained in a place like a hospital or care home when it is in their best interests.

This is known as a deprivation of liberty and a proper authorisation process should be in place to ensure it is done lawfully.

New figures from NHS Digital show that Deprivation of Liberty Safeguards (DoLS) applications in England reached 217,235 during 2016/17, the highest since they were introduced in 2009.

This represents an 11% rise on the previous year.

But just three in four new applications are completed, the figures show.

Standard applications should be completed within 21 days, but the proportion that were completed within this time-frame fell to 23% in 2016/17, the figures show.

The average length of time to complete a DoLS application increased from 83 days in 2015/16 to 120 days in 2016/17, the data shows.

Meanwhile, the number that took more than one year to be completed was 14,765 - a 244% increase on the previous year.

Earlier this year, a Law Commission review concluded that the DoLS system should be replaced with a "matter of pressing urgency".

The Government-commissioned review concluded that thousands of vulnerable people are being detained without the appropriate checks.

The Commission said that an increasing number of DoLS referrals are also being left unassessed and statutory time-scales are being "routinely breached".

A Supreme Court judgment in March 2014, which introduced an ''acid test'' for depriving people of their liberty, has fuelled a rise in applications from places such as care homes.

The Law Commission, an independent body set up to review laws, said that since the landmark legal case, local authorities have been under increased administrative pressures.

It set out how the system should be replaced - including giving patients enhanced rights to advocacy and periodic checks on their care or treatment arrangements.

When a person is the subject of DoLS, measures can be used to control them, including the use of locks on doors and straps on chairs and wheelchairs.

The person can be made to stay somewhere against their wishes or the wishes of a family member, have regular sedation to control their behaviour or have objects or belongings removed for their safety.

Earlier this week, Health Minister Jackie Doyle-Price gave an interim response to the report.

She said in a written ministerial statement: "I welcome the publication of the Law Commission's report which we are carefully considering and thank them for their careful and considered work. We will now engage with a range of stakeholders to understand in greater detail how these changes can be implemented.

"This Government is committed to take action to reform mental health and transforming care for people with conditions such as dementia, learning difficulties and autism.

"Action to reform the current Deprivation of Liberty Safeguards regime is an important contribution towards achieving these aims including effectively protecting some of the most vulnerable people in our society."

Ministers will fully respond to the report in the spring, she said.

The Alzheimer's Society said the figures showed an "unacceptable number of people are being left in limbo".

But the Local Government Association (LGA), which represents councils, said that despite the rise in applications, the number of applications completed increased by 45%.

Izzi Seccombe, chairwoman of the LGA's Community Wellbeing Board, said: "Following the Supreme Court judgment in March 2014, there was a just under 70% increase in completed assessments from councils between 2014/15 and 2015/16.

"This increased activity has caused significant cost pressures on council budgets at a time when adult social care services face a £2.3 billion funding gap by 2020.

"We have long warned of the need to overhaul the current DoLs process so that councils have the time and money to do this properly.

"Failure to do this both will have a damaging impact on crucial council services on which people rely and will lead to both some of the most vulnerable people in our communities continuing to face long waiting times for assessments.

"We look forward to working with government to develop a reformed, fully funded scheme so that councils can ensure that everyone who lacks mental capacity is at the heart of decisions made about their care."