AIB is to return almost €400,000 to customers it overcharged on tracker mortgages between 2002 and 2007.

The overcharging affects 436 mortgages with the average refund being €906.

The bank said the Financial Regulator had been informed of the mistake.

In a statement to RTÉ News, AIB said it offered different tracker rates to customers based on the loan-to-value ratio of their mortgage.

In some cases the error happened when customers were charged an interest rate that did not match the loan-to-value ratio on their account.

In other cases new AIB customers who should have been entitled to a new business discount did not receive that reduction.

The bank has declined to say when it found out about the problem, but said it was discovered during a standard internal review process.

Affected customers were notified by way of letters sent on Monday.