President Reagan, reversing an earlier position, promised to support peanut-price legislation in return for southern Democratic votes for his tax-cut bill in the House this week.

Reagan's reversal on peanuts clinched at least five Democratic votes for his side, four of them from Georgia, the major peanut state.

As it turned out, with his 43-vote margin Reagan did not need the five, but the agreement was worked out at a time when most headcounts showed an extremely close vote looming Wednesday in the House.

According to sources in the administration and on Capitol Hill, the White House peanut agreement was ratified in writing in an unusual memo signed by David A. Stockman, the budget director, and John R. Block, the secretary of Agriculture.

The administration's change of heart on peanuts was its second such reversal in less than a month on an agricultural policy question in an effort to win votes for the president's economic program.

The first switch came on sugar price supports in the pending House and Senate farm bills. The administration opposed the support levels in the bills as inflationary, but altered course to win votes from sugar-state congressmen for Reagan's proposed budget cuts.

The goober gambit, first reported by Georgia newspapers, was engineered by Rep. Billy Lee Evans, a Democrat whose south Georgia district is a leading peanut area, in personal discussions with Reagan. Evans insisted in an interview, however, that the accomodation did not result in any changed votes.

"It was not a deal. I told the president that I agreed with him in principal on his economic program, but that his agriculture policy was hurting us and we needed some help on peanuts. I told him I had five votes leaning toward support of his tax bill if we could get some help on peanuts," Evans said.

The Georgian conceded, however, that. "The Truth is, they were going to support him anyway . . . We wanted help and we got it."

With Evans on the Democratic peanut brigade were Georgians Bo Ginn, Charles Hatcher and Jack Brinkley and Texan Charles W. Stenholm, leader of the Southern Democratic coalition in the House and strong backer of Reagan's budget-cutting program. Stenholm also represents a major peanut-producing district.

The high-pressure atmosphere on the tax bill was underscored when a former Georgia peanut farmer, Jimmy Carter, personally called Ginn this week urging him to stick with the Democratic Party position. The Georgia delegation was one of those most avidly courted. Headcounts the day before the vote showed it going 7 to 3 against Regan; on final passage, it went with the president, 8 to 2.

Apparently mindful of confusion that followed the president's earlier promise to support sugar portions of the farm bill, the southerners obligated the administration to put its peanut committment in writing. "I am an attorney . . . so there are no misunderstanding," Evans explained.

The commitment aligns the White House behind the House Agriculture Committee's unanimously adopted provisions on peanuts, setting the price support for fiscal 1982 at $600 at ton, with an escalator clause for future years. The present support is $455 a ton.

Higher support levels would increase the prices that processors must pay for raw peanuts. The highest prices that processors must pay for raw peanuts. The higher prices, in turn, would show up in finished products, although market experts agree they would show up in larg part by the drought that devastated the 1980 crop.

The House and Senate approach also retains the system of peanut acreage allotments and poundage quotas.These supply-regulating devices to prop up prices were strongly opposed by the administration until this week.

In line with their professed policy of reducing government involvement in farm programs and promoting agricultural free trade, Reagan and Block had urged Congress to phase out the peanut allotment and acreage control system.

But both House and Senate Agriculture committees ignored the administration's proposals and extended the present program in essentially its same form. Sen. Richard G. Lugar (R-Ind.) intends to attack the peanut program when the farm bill reaches the Senate floor next month.

Lugar has 27 co-sponsors on his amendment, and his allies are confident they can muster enough votes to wipe out the peanut program. The administration's new commitment to stand behind the House version, through a final conference committee on the farm bill, would strengthen the Georgian's hand.

Evans said that he had not been lobbied on peanuts by former president Carter, but that Rosalynn Carter, had contacted him on the budget vote, urging him to suport health-care spending, which he did.

"You could say I helped the old Gipper with that one," Evans said, "and I helped the new Gipper on the tax bill. I feel real good about it." CAPTION:

Picture, At Camp David last Sunday, Democratic House members were wooed by President Reagan. Second from left is Billy Lee Evans of Georgia, engineer of goober gambit. AP