Switzerland and the US have signed an agreement designed to end a tax evasion dispute surrounding UBS’s American customers.

The Swiss government has agreed to hand over details of about 4,450 UBS bank accounts to US authorities, settling a tax dispute that has threatened Swiss banking secrecy.

It has also agreed to review and process requests by the US seeking information from Swiss banks besides UBS about account holders who may have tried to evade taxes.

The agreement ends a row which has strained relations between the US and Switzerland and challenged the latter’s jealously guarded bank secrecy laws.

It could help UBS, the world’s second-largest wealth manager, restore an image that has been battered by the financial crisis and the US dispute, and may open the way for the Swiss government to sell its stake in UBS.

“It’s good to get this out of the way but the confidence of a lot of clients has been compromised so I’m not sure we will see inflows return in the third quarter. It will take time to recover reputation from this,” said Jaap Meijer, analyst at Evolution Securities in London.

Switzerland’s Finance Minister Hans-Rudolf Merz said the government wants to sell its stake as quickly as possible and while it would be good business, it also has to consider other factors.

UBS shares were down 1.6 per cent shortly after the announcement. Swiss rival Credit Suisse was down one per cent and Julius Baer dropped 0.5 per cent.

The new treaty between the United States and Switzerland would allow action in the case of “tax fraud and the like” in the UBS case, and affects about 4,450 accounts, the Swiss government said. Precise details will be published 90 days after the agreement comes into force.

The client accounts to be disclosed will likely belong to people suspected of committing tax fraud under the terms of a double taxation agreement that obliges Switzerland to provide help if Washington seeks it in a criminal investigation.