A government program to bail out banks at the height of the financial crisis has so far turned a profit, according to a report by investment bank Keefe, Bruyette & Woods.

The Capital Purchase Program, part of the $700 billion Troubled Asset Relief Program, has generated an average return of 10 percent on the initial investment in 61 banks that have fully repaid the aid, said the report, issued on Wednesday.

About $137 billion, or two-thirds of the initial government investment, has been paid back, with $65 billion still to be repaid, the report said.

The often controversial program injected taxpayer funds into 707 banks nationwide in an effort to prop up the financial system at the height of the crisis in 2008 and 2009.

The KBW study found the U.S. Treasury has received $13 billion in earned income and $2.3 billion in posted losses in the program so far.

Six banks produced a return on investment for the government greater than 20 percent, according to the study.

Most major U.S. lenders repaid their government bailout aid in 2009 and early 2010. The remaining participants in the program are mostly smaller community and regional banks.

The program currently has $65 billion in outstanding investments in 632 U.S. banks, with $4 billion in reported missed interest payments.

Under the terms of the program, U.S. Treasury received quarterly dividend payments from the banks and warrants that could be converted to common stock.

TARP was originally scheduled to shut down on Oct. 3, 2010, but it is expected to be shuttered earlier as part of sweeping U.S. financial reform.