President Reagan, making good on a campaign promise, yesterday announced he will ask Congress to dismantle the four-year-old Department of Energy and transfer most of its functions to the Commerce Department.

"This plan will result in a strong federal effort in basic research in energy that avoids . . . excessive regulation," Reagan said in a statement read at the White House by Energy Secretary James B. Edwards.

The reorganization proposal was unveiled after weeks of what one Cabinet secretary described as "spirited debate" within the administration. Both Edwards and Interior Secretary James G. Watt had sought to have the bulk of the department transferred not to Commerce but Interior, sources said.

These sources said Interior was ruled out in part for fear that it would add to controversy over the plan to give too much of Energy to Watt, who has become a lightning rod for critics of the administration.

Under the Reagan plan, Interior would receive less than one-quarter of the $11.5 billion 17,700-employe Energy Department's programs, including the administration of the strategic petroleum reserve and the operation of government-owned hydroelectric dams.

The Commerce Department would assume control of the nation's $6 billion nuclear weapons production program, which would operate as a semi-autonomous agency under Commerce Secretary Malcolm Baldrige. All of the government's energy-related research and development programs also would be transferred to Commerce, as would policy-making power over the strategic petroleum reserve.

The reorganization will add significantly to Commerce, which now has one of the smaller roles among federal departments.

Both Edwards and Baldrige predicted congressional approval of the plan, but early reaction from Capitol Hill yesterday indicated it could have problems there.

House Speaker Thomas P. (Tip) O'Neill Jr. (D-Mass.) denounced the proposal as "purely a political move, absolutely the wrong thing to do." Sen. Henry M. Jackson (D-Wash), ranking minority member on the Senate Energy and Natural Resources Committee, called it a "tragedy" that sends a message abroad that this nation was weakening its commitment to energy independence.

Congressional opposition is expected to come from two fronts: environmentralists who fear that research into so-called alternative energy sources, already downgraded by the Reagan administration, will be lost altogether with the dismantling of the department; and defense hard-liners who do not want to place the nation's nuclear weapons production program in a department whose focus is business development and trade.

Chairman John G. Tower (R-Tex.) and 12 other members of the Armed Services Committee spelled out their objections to the weapons program transfer last week in a letter to Reagan.

Edwards yesterday defended the decision to transfer the weapons production program to Commerce by quoting the old saying that "war is too important for the generals." He noted that since the dawn of the atomic age, this country has had a tradition of civilian control over nuclear weapons production.

Both Edwards and Watt sidestepped questions yesterday about their opposition to aspects of the plan. Watt said in a statement that he "fully supported" the president's proposal, but went on to note that he had been unable to persaude the Cabinet that Interior, "with its historic tradition of resource protection, would be the appropriate place to house the nuclear power option that is so essential for the consumers of America."

Edwards said the president would submit the proposal to Congress along with his budget message in January. He said he expected to be "back to the beaches of South Carolina" by mid-summer. A former dentist who served as governor of South Carolina from 1975-79, Edwards said he has no plans to hold or seek public office after he closes down the department, which was created in the Carter administration.

Although the planned dismantlement has been advertised by Reagan as a cost-cutting move, no one in the administration gave figures yesterday on the projected savings in dollars and jobs.