Depressed energy issues staged a late rally today, and Democrats in the House proposed business tax cuts, enabling the stock market to wipe out some early losses and finish with a modest gain.

Stocks turned higher in the final minutes of trading, partly because of word from Washington that the House Ways and Means Committee was pushing ahead on tax bill work. A Democratic task force proposed to cut the corporate tax rate to 34 percent by 1987 as part of a substitute for the Reagan administration's accelerated depreciation plan.

In the bond markets, however, prices fell sharply in all sectors by as much as 1 3/4 points, as the Federal Funds rate charged by banks for overnight lending soared to as high as 28 percent. The high cost of financing combined with worries over the supply of money took its toll in credit markets.

The Dow Jones average of 30 industrials stocks on the New York Stock Exchange, off more than 6 points in mid-afternoon, closed up 3.23 at 1,006.56.

The daily tally on the NYSE showed advances slightly outnumbering declines, and the exchange's composite index rose .54 to 77.34.

Virtually all of the Dow's rise stemmed from the upswing in the three oil issues among its components -- Exxon, up 1 3/8 at 35 1/4 as of the 4 p.m. close in New York; Standard Oil of California, up 1 1/2 at 37, and Texaco, up 1 1/8 at 34 7/8.

Elsewhere in the energy sector, Mobil gained 1 3/4 to 57 3/8; Union Oil of California 2 3/8 to 32; Amerada Hess 1 5/8 to 28 1/2; Standard Oil of Indiana 2 7/8 to 52 7/8, and Superior Oil 7 1/4 to 183 1/4.

American Telephone & Telegraph pickup up 1/4 to 58 3/8. The company reported earnings for the three months ended May 31 of $2.06 a share, against $1.99 in the comparable period last year.

Big Board volume totaled 55.47 million shares, down from 57.78 million Tuesday.

Standard & Poor's index of 400 industrials rose 1.57 to 149.47, and S&P's 500-stock composite index was up 1.17 at 133.32.

At the American Stock Exchange the market value index gained 4.00 to 367.42. The NAS-DAQ composite index for the OTC market closed at 220.61, up .03.