By Jesús Aguado and Emma Rumney

A botched migration of TSB computer systems in April saw thousands of users locked out of their accounts and a surge in attacks by fraudsters, prompting a regulatory investigation and criticism of its chief executive.

Sabadell, which bought TSB in 2015, booked an extraordinary charge of 203 million euros for the outage, including compensation for cases of alleged fraud during the migration and 92.4 million euros for future customer claims.

Sabadell had estimated the cost at around 70 million pounds ($91.7 million) in a statement last month.

Sabadell shares fell around 6 percent to 1.34 euros on the Madrid stock exchange by 0830 GMT after it reported a loss of 138.7 million euros for the second quarter.

TSB Chief Executive Paul Pester told Reuters he expected everything to be back to normal in terms of serving existing customers and attracting new ones by the first quarter of 2019.

Some services for new customers are currently limited while the bank ensures it serves its 5 million existing customers as usual.

Pester said he planned to stay at the bank despite criticism from lawmakers and a backlash from customers hit by the failure.

The bank's handling of the crisis has tarnished its reputation just as it tried to win more market share in Britain and offset a squeeze in margins in its Spanish home market as a result of ultra low interest rates in the euro zone.

"We're making progress in resolving the service problems customers experienced following our IT migration, and we will continue to work tirelessly until we have put things right," Pester said.

COST IMPACT

TSB reported a pre-tax loss of 107.4 million pounds.

Around 80 percent of the additional costs booked in the first half of the year are not expected to recur, TSB's Chief Financial Officer Ralph Coates said.

The bank said additional costs will mainly be due to paying extra resources added to cope with the crisis, including 1,800 new staff, rather than compensation claims for customers, fraud or lost profits from waived fees.

Sabadell's net interest income, or profit from loans minus funding costs, fell 7.8 percent in the quarter from the same period last year to 899 million euros, also hit by TSB.

Analysts were mixed on the results.

Mirabaud and Goldman Sachs said the bank had now drawn a line under the main risks looming over its balance sheet, including TSB and non performing real estate assets. But RBC Capital Markets noted the impact of the outage would still be felt going into 2019.

At group level, earnings were also impacted by several one-offs linked to the disposal of Italian bonds, a debt impairment at Spain's bad bank and charges linked to the sale of bad property assets.

(Reporting By Jesús Aguado and Emma Rumney; Editing by Julien Toyer and Keith Weir)

By Jesús Aguado and Emma Rumney