The quality of service provided by HM Revenue and Customs (HMRC) for personal taxpayers "collapsed" amid staff cuts, a report has found.

The National Audit Office (NAO) said HMRC got its timing badly wrong when rolling out its digital strategy, which involves moving more personal taxpayers online and reducing demand for telephone and postal contact, which are more costly to handle.

While HMRC maintained or improved its customer service up to 2013-14, it then misjudged the overall impact of its complex transition and shed too many customer service staff before completing service changes, the NAO said.

It said: "The quality of service provided by HMRC for personal taxpayers collapsed in 2014-15 and the first seven months of 2015-16 when average call waiting times tripled.

"Services have subsequently improved following the recruitment of additional staff but whether this performance is sustainable depends on HMRC achieving successful outcomes from its programme to make tax digital."

The NAO estimates the overall cost incurred by customers who called the taxes helpline increased from £63 million in 2012-13 to £97 million in 2015-16.

The estimate includes call charges at £10 million, the value of customers' time spent waiting to speak to an adviser at £66 million and value of time spent talking to advisers at £21 million.

Within this estimate, customers paid £2 million less in call costs because HMRC reduced call charges by moving from higher-rate numbers to local-rate "03" telephone numbers in September 2013.

But an increase in the economic cost of time spent waiting for an answer or speaking to an adviser more than offset this saving, the NAO said.

An NAO survey of customers using HMRC services found 58% rated the service as good or excellent, 21% as average and one in five (21%) rated it as poor or terrible.

Between 2010-11 and 2014-15, HMRC cut staff numbers in personal tax from 26,000 to 15,000. The reductions would be achieved in part by moving customers to less expensive contact through the expansion of HMRC's digital services.

HMRC introduced automated telephony and paperless self-assessment in 2013-14 - but demand for telephone advice did not fall and the quality of service deteriorated in 2014-15 when the full extent of the staff reductions took effect, the report found.

HMRC met its target to handle 80% of call attempts in only 10 weeks of the year, the report said. Its performance deteriorated further over the first seven months of 2015-16. Average waiting times tripled compared to 2014-15 levels.

To protect the service experienced by callers to the tax helpline in 2014-15, HMRC transferred to its call centre's back-office staff who had been maintaining PAYE (pay-as-you-earn) tax records. The stock of outstanding discrepancies in tax records requiring investigation rose from 2.4 million at March 2014 to 4.6 million at March 2015. Of these items, 3.2 million were high-priority cases, carrying a risk that employees would have paid the wrong amount of tax.

Performance recovered after HMRC recruited 2,400 staff to the taxes helpline in autumn 2015. Call waiting times improved to an average of five minutes for self-assessment callers during the deadline week for online returns in January 2016.

The revenue body is introducing digital tax accounts so that by 2020 most taxpayers will provide information through a live tax account rather than by completing an annual tax return. HMRC expects the changes to increase efficiency, reduce the admin burden for customers and improve overall levels of tax compliance.

Amyas Morse, head of the NAO, said: "HMRC's overall strategy of using digitally enabled information to improve efficiency and deliver service in new ways make sense to the NAO.

"This does not change the fact that they got their timing badly wrong in 2014, letting significant numbers of call handling staff go before their new approach was working reliably. This led to a collapse in service quality and forced a rapid expansion of headcount.

"HMRC needs to move forward carefully and get their strategy back on track while maintaining, and hopefully improving, service standards".

Ruth Owen, HMRC's director general for customer services, said: "We recognise that early in 2015 we didn't provide the standard of service that people are entitled to expect and we apologised at the time. We have since fully recovered and are now offering our best service levels in years.

"Over the past six months we've consistently answered calls in an average of six minutes, and have launched new online tax accounts and webchat for everyone, enabling customers to manage their tax affairs wherever and whenever they want.

"There's never been a better or more convenient service for our customers."

Gillian Guy, chief executive of Citizens Advice, said: "Waiting on the phone to HMRC has put some people at risk of debt. Long waiting times not only cause frustration and increase the cost of the call, but can also mean people miss important deadlines."

Alex Neill, Which? director of policy and campaigns, said: "Which? research for the last two years has shown just how difficult it can be to get through to HMRC and consumers deserve a big improvement in call waiting times.

"Until people have viable alternatives to ringing when they need to discuss their tax affairs, many feel they have no choice but to wait. HMRC must continue to work hard to tackle their customer service and reduce call waiting times."