Stocks edged higher on Friday on talk the European Central Bank could add liquidity to stabilize the region's banking system, but continued fears about a global recession kept markets choppy.

Concerns about the sovereign debt crisis worsening in Europe have contributed to recent equity losses, with both the Dow and S&P off nearly 7 percent, and the Nasdaq down almost 6 percent this week.

Earlier stocks seesawed between gains and losses on any indication from policymakers suggesting additional steps to support Europe's financial system.

One such comment came from Ewald Nowotny, European Central Bank Governing Council member, who said it might be advisable for the ECB to add more liquidity into the banking system.

The European issue is pretty significant, said Nick Kalivas, vice president of financial research & senior equity index analyst at MF Global in Chicago.

It suggests some of the money could go to the bondholders of countries with troubled debt. People see that as maybe a sign of some capital for banks or maybe mitigating loss, so that is certainly a factor.

The Dow Jones industrial average <.DJI> gained 2.68 points, or 0.02 percent, to 10,736.51. The Standard & Poor's 500 Index <.SPX> rose 4.53 points, or 0.40 percent, to 1,134.09. The Nasdaq Composite Index <.IXIC> added 20.59 points, or 0.84 percent, to 2,476.26.

Even with the heavy declines this week, the S&P was able to hold above the August 8 low of 1,119, viewed as a key support level.

Gains in the Nasdaq were helped by strength in semiconductor stocks, with the PHLX index <.SOX> up 1.7 percent. Texas Instruments gained 2.4 percent to $26.87 after Caris boosted its rating on the stock.

Hewlett-Packard Co was down 4.3 percent to $21.83 a day after Meg Whitman, the former head of EBay Inc , was named to run the computer and printer maker. The move was met with criticism of the company's board, which has been blamed for a series of recent missteps.

(Reporting by Chuck Mikolajczak; Editing by Kenneth Barry)