Washington Mutual Inc received long-sought court approval to exit bankruptcy and repay $7 billion to creditors, ending more than three years of court battles between hedge funds investors, shareholders and JPMorgan Chase & Co .

The reorganization plan will distribute the money to creditors, many of which are hedge fund investors who specialize in buying securities of bankrupt companies.

The former parent of Washington Mutual bank, the largest bank to fail in U.S. history, postponed the start of a confirmation hearing on Thursday for last-minute talks to win over a group of holdout preferred shareholders.

Once that deal was clinched in the early afternoon, the bank holding company had the support of every class of creditors for its reorganization plan.

WaMu said in a statement on Friday that Judge Mary Walrath, of U.S. Bankruptcy Court in Delaware, will enter an order officially confirming the plan.

William Kosturos, the bank's chief restructuring officer, called the confirmation a monumental achievement, saying in a statement the company is looking forward to putting the plan in place and starting to pay back its creditors.

A small mortgage reinsurance business will exit bankruptcy, owned by the preferred and common shareholders of Washington Mutual. Shareholders had fought for ownership of the reorganized company, which they argued will own tax credits worth billions of dollars. Washington Mutual and its creditors have played down the value of the tax benefits.

Washington Mutual's namesake lending business was seized by regulators in September 2008 at the height of the financial panic.

The bank was immediately sold by the Federal Deposit Insurance Corp to JPMorgan Chase & Co for $1.88 billion. Washington Mutual filed for bankruptcy the next day, and legal battles quickly followed over who owned which assets.

The confirmation hearing was the company's third attempt to end its bankruptcy.

Judge Walrath rejected the company's two previous plans, in part because of her concerns that a group of hedge funds had used their role negotiating the bankruptcy plan to exploit nonpublic information in trading Washington Mutual securities.

The case is In re Washington Mutual, U.S. Bankruptcy Court, District of Delaware, No. 08-12229.

(Reporting By Tom Hals in Delaware; additional reporting by Nick Brown in New York; Editing by Phil Berlowitz)