Shares in Royal Bank of Scotland climbed over 3.5% early on Friday (4 August), after the bank posted a profit in the first half for the first time in three years.

In the six months to 30 June, the banking giant swung to an attributable profit of £939m, compared with a £2bn loss in the corresponding period last year. Operating profits rose to £1.9bn from a £274m loss last year, even though the bank was forced to set aside £342m in the second quarter of the year to deal with some lingering legacy issues.

While the first half profit marks the first time since 2014 that the lender, which is still 71% owned by the taxpayers, swung into the black, group chief executive Ross McEwan warned the bank still had work to do.

"We're doing what we said we would at our full-year results in February – growing income, reducing cost and improving returns for shareholders, while also starting to deliver a better service for customers," he said.

"We see the first six months of this year as proof of the investment case for this bank: our path to sustainable profitability is becoming clearer and closer and we have resolved some of the most significant issues this bank faced,

The FTSE 100-listed lender, which in July reached a $5.5bn settlement over claims that it mis-sold toxic mortgage-backed securities with a key US regulator, also set out its plans to deal with a hard Brexit scenario.

RBS said its NatWest division, which forms the core of its investment banking business, was reviewing plans to "minimise disruption to the business and continue to serve its customers well in the event of any loss of EU passporting".

The bank said discussions with the Dutch national bank over the possibility of setting up a European headquarters in the Netherlands were at an advanced stage. Implementing the plan would cost "tens of millions" of pounds and would see the bank employ approximately 150 staff in Amsterdam, where it already holds a banking licence, following its takeover of Dutch bank ABN Amro a decade ago.

Last month, the National Audit Office (NAO) revealed taxpayers were left nursing a much bigger than expected loss after the Government's decision to sell shares in RBS.

In August 2015, UK Financial Investments Limited (UKFI), which manages the government's stake in the bailed-out bank, raised £2.1bn after selling a 5.4% stake in the FTSE 100-listed lender to investors at 330p per share.

The sale attracted severe criticism, as the Government opted to sell the bank's shares, which had tumbled 8% in the three days preceding the sale, while they languished at a 52-week low. The sale was forecast to represent a £1.1bn loss for taxpayers, based on the price at which the Government had put together a £45.5bn bailout during the financial crisis.

However, the NAO said the losses stemming from the share sale totalled £1.9bn, though it added the shares were sold at a price within the "fair value range" and that the sale was "well planned and organised and represented value for money".