The European Commission has formally approved an "alternative remedies package" that will allow Royal Bank of Scotland to avoid the compulsory sale of its Williams & Glyn branches by doling out £835 million.

The announcement effectively rubber stamps a plan that was first outlined in July following a review by the commission and HM Treasury, and helps fulfil RBS's state aid obligations following its government bailout at the height of the financial crisis.

The package includes a £425 million fund aimed at competitors across the UK's banking and fintech sectors, as well as a £350 million pot meant to help challenger banks convince small and medium-sized businesses - which were previously Williams & Glyn customers - to switch accounts and loans from RBS.

RBS - which is still around 73% owned by the Government - will shell out another £60 million to cover additional costs, which will help finance the proposal's implementation.

The bank said the costs were covered by the provisions it set aside across the second half of 2016 and the first half of 2017.

The plan ultimately saves RBS from hiving off its near-300 Williams & Glyn branches, having struggled to find a buyer ahead of its deadline, which was set for the end of 2017.

RBS chief executive Ross McEwan said: "We are pleased that we now have final approval from the European Commission for the alternative remedies package.

"This allows us to resolve our final state aid divestment obligation and brings welcome clarity for our customers and staff.

"It also builds on the progress we have made already this year in resolving our major legacy issues through reaching a settlement with the Federal Housing Finance Agency, and resolving the 2008 rights issue litigation."

Mr McEwan was referring to RBS's recent £4.2 billion US settlement over claims it mis-sold toxic mortgage bonds in the run-up to the financial crisis.

"We remain committed to resolving our last remaining major legacy issue, the investigation into our historic US RMBS activities," he added.