The Merrill Lynch deal was first questioned after Bank of America disclosed that Merrill's losses were far more than expected.
Bank of America went on to receive $45bn in government assistance, in part to offset those losses, and came under attack when it was revealed that it had given billions of dollars in bonuses to Merrill employees.
In a letter to employees, Lewis said his retirement was his decision, and not the result of outside pressure, either from the board, or regulators and the government.
However, many experts believe it was the intense scrutiny from federal regulators, state attorneys-general and the courts that forced Lewis' hand.
The bank did not announce a successor, saying one would be selected by the time Lewis steps down on December 31.
Lewis built the largest US retail banking franchise through aggressive acquisitions, yet his last deal appears to have been his undoing.
The deal was forged a year ago at the height of the financial crisis and closed on January 1, the Merrill bonuses, which would normally have been paid in January, were moved up and paid out in December.
Bob Stickler, a Bank of America spokesman, said Lewis had not been asked to leave by the board or the bank's regulators.
"He made the decision himself," he said.
Stickler said Lewis informed the bank's board about his decision during an unscheduled meeting conducted by telephone on Wednesday evening.
"The board was surprised when Ken told them what he wanted to do," Stickler said.
He said Lewis had started thinking about stepping down after returning from holiday in August.
Stickler said Lewis's decision was driven by the fact that the bank is in better shape to recover from the recession and because "I think he's just feeling a little burned out for pretty obvious reasons".
Walter Todd, portfolio manager for Greenwood Capital Associates, said: "It's a good thing for the company to make a clean break and move forward."
Todd said that regardless of the reality, "the perception is, everything that happened with the Merrill transaction was his fault, and for Bank of America to move beyond that, Lewis would have to go".
Lewis's departure underlines the dramatic change there has been at the top of the nation's banks in the past two years.
Only Lloyd Blankfein, the head of Goldman Sachs, and Jamie Dimon, chief executive of JPMorgan Chase, have survived.
Bank of America shares, which have shed 50 per cent since the Merrill Lynch deal was announced on September 15, 2008, the same day Lehman Brothers declared bankruptcy, were up two per cent in after-hours trading.