Ross McEwan’s departure from Royal Bank of Scotland marks the end of an era for the taxpayer-owned lender as it moves on from a torrid past decade.

The 61-year-old New Zealander took over in October 2013, when RBS was still suffering the aftershocks of its £45 billion taxpayer bailout in 2008 at the height of the financial crisis.

When he took the helm, it was more than 80% owned by the Government, but the taxpayer’s stake has since reduced to 62.4%.

One of his challenges was to prepare the bank to be returned to private hands – a task still not complete, but with progress being made.

To this end, he has presided over a return to profit at RBS, which in February reported its second successive year in the black and announced a £1.6 billion final dividend, resulting in a near £1 billion windfall for the taxpayer.

RBS chairman Sir Howard Davies said his efforts have helped deliver “one of the biggest UK corporate turnarounds in history”.

But the bank’s scandal over its treatment of small businesses marked a black spot on his tenure.

RBS saw its reputation suffer after its notorious turnaround unit, the Global Restructuring Group (GRG), was accused of deliberately pushing firms towards failure in the hope of picking up assets on the cheap.

The group and its senior management escaped action over the scandal, after the Financial Conduct Authority concluded GRG’s activities were not within its remit and that its powers did not apply.

Michael Hewson, chief market analyst at CMC Markets, said: “While the timing is surprising, McEwan can consider the past few years a job well done, with the underlying business profitable, and most legacy issues in the rear view mirror.”

“RBS is undoubtedly in better shape than when he joined, and while one can legitimately question some of the banks actions in terms of responsibility over what happened with the banks GRG unit, the bank is on a much more solid foundation than when he took over,” he added.

During his time in the top job, Mr McEwan has also resolved most of the outstanding penalties and fines that had hung over the group.

It struck a 4.9 billion US dollar (£3.8 billion) settlement with US authorities last year over claims that it mis-sold mortgages in the run-up to the financial crisis.

That opened the door for it to resume paying dividends last August in a milestone move for RBS.

But Mr McEwan was seen as the nearly man of Australian banking before his ascent to the top of RBS.

His appointment as chief executive in 2013 came two years after a surprise decision saw him passed over in the race to become head of Commonwealth Bank of Australia (CBA).

Mr McEwan, who was head of CBA’s retail business, was widely seen as having been groomed for the role.

The married father-of-two then accepted an offer to become head of RBS’s retail arm in 2012.

The resignation in 2013 of Stephen Hester amid claims of political interference paved the way for Mr McEwan to take charge.

The Kiwi had previously worked in the insurance and investment industries for more than 25 years, including as managing director of stockbroking business First NZ Capital Securities and chief executive of AXA New Zealand.