Embattled rail and bus operator FirstGroup named the boss of insurance giant Aviva as its new chairman in a move ending a six month for his replacement.

John McFarlane, chairman of Norwich-based Aviva, will take on the same role at FirstGroup in place of Martin Gilbert, who heeded investor calls in May by announcing plans to step down after the firm tapped investors for £615million and cancelled its shareholder dividend.

Mr McFarlane will join the board of FirstGroup immediately and will take on the post of chairman on January 1.

The appointment comes as Aberdeen-based FirstGroup, a major operator of business services in East Anglia, recovers from a turbulent year in which its growth plans were derailed by the botched bidding process surrounding the West Coast mainline.

It reported half-year pre-tax losses of £8 million last month, although this was a marked improvement on the £20.6m loss seen a year earlier.

The group, which operates First Great Western, First Capital Connect and First ScotRail, said on reporting interims that it was getting back on track and hoped to start repaying dividends from the close of its financial year.

It is pouring £1.6billion into a four-year investment programme and tackling debts of nearly £2 billion.

John Sievwright, senior independent non-executive director at FirstGroup, said Mr McFarlane's experience will be 'invaluable' to the firm.

He also paid tribute to Mr Gilbert, who has chaired FirstGroup and its predecessor companies for 27 years.

'On behalf of the board and everyone at FirstGroup I would like to thank him for his enormous contribution to the group over many years,' he said.

Mr McFarlane became chairman of Aviva in July 2012, promising to turn it into a 'leaner, more agile beast'.

Analysts at Shore Capital Stockbrokers said Mr McFarlane's appointment at FirstGroup was 'very encouraging'.

'The swift action and turnaround at Aviva under his executive stewardship is a welcome read across to FirstGroup as it continues to grapple with the previous regimes legacy of underinvestment,' they added.

Mr McFarlane has also served as a non-executive director at Royal Bank of Scotland and previously headed Australian and New Zealand banking giant ANZ as chief executive for 10 years.

He said he was pleased to be joining FirstGroup at an 'important stage of its evolution'.

'The group has short-term challenges which we will naturally need to overcome, but I am convinced it has significant opportunity to benefit from its market-leading positions and to deliver sustainable long-term value for shareholders,' he added.

Born in Dumfries, Scotland, he began his career at the Ford Motor Company in manufacturing.