The Supreme Court ruled 7 to 0 yesterday that federal judges have only a limited role in decisions on the safety and necessity of nuclear power.

Justice William H. Rehnquist spoke from the bench of "judicial intervention run riot," in denouncing decisions by the Court of Appeals for the District of Columbia.

The rulings overturned yesterday involved Vermont Yankee Nuclear Corp., which got a permit in 1967 to build a nuclear plant in Vernon, Vt., and Consumers Power Co., which got a permit in 1969 - and already has spent $350 million - to build two reactors in Midland, Mich., Environmentalists opposed both companies nuclear plans.

In the opinion for the court, Rehnquist wrote that the decisions "improperly intruded" into a decision-making process entrusted by Congress to the Atomic Energy Commission, which has been incorporated into the Nuclear Regulatory Commission.

The appeals court "engrafted" its own notions of proper procedures in deciding questions about disposal of radioactive wastes in the Vermont Yankee case and about energy conservation in the Consumers Power case, Rehnquist said.

"The fundamental questions appropriately resolved in Congress . . . are not subject to reexamination in the federal courts under the guise of judicial review of agency action," Rehniquist said. He added:

"Time may prove wrong the decision to develop nuclea energy, but it is Congress or the states within their appropriate agencies which eventually must make that judgement. In the meantime, courts should perform their appointed function."

The ruling may herald limits on the ability of environmental groups to oppose nuclear power.

The Atomic Industrial Forum, an industry group, termed the unanimous decision "one of the strongest endorsements possible for nuclear licensing procedure."

The ruling is also "good news, most of all for consumer," said forum president Carl Walske."

At the same time, the Natural Resources Defense Council, which opposed Vermont Yankee, said the decision left it "optimistic."

NRDC spokesman Richard Ayres told a reporter that its position is that the government "had failed utterly to demonstrate that if had a solution" to the problem of storing hundreds of thousands of years needed for them to decay into harmlessness.

Because the justices took "the unusual step" of sending the issue back to the appellate court on their own initiative, they indicated their own "serious doubts" about the NRC's assurances that it will find a means to store wastes safely, Ayres said.

After Vermont Yankee got a construction permit from the old AEC, it applied for a license to operate the plant. The NRDC opposed licensing. Over the NRDC's objection, the agency excluded the issue of environmental effects of operations to reprocess fuel or dispose of wastes resulting from reprocessing.

In November 1972, however, the commission started a rule-making proceeding "that would specifically deal with . . . environmental effects associated with the uranium fuel cycle . . ."

Finally, in April 1974, the commission adopted a rule assigning numerical values for the environmental impact of fuel reprocessing, in order to help determine overall cost-benefit ratios. The commission, holding that the effects of the uranium fuel cycle had been shown to be "relatively insignificant," granted the license. The NRDC then went to the appeals court.

In the Consumers Power Co. case two environmental groups known as "Saginaw" and Mapleton" raised energy-conservation issues in opposing approval of a construction permit. After lengthy proceedings, however, the commission's licensing board issued the permit, saying it was beyond its province to deal with such issues.

The commission declined to review the decision. At about the same time, the White House Council on Environmental Quality revised its regulations for environmental impact statements to mention, for the first time, a need to consider energy conservation.

Trying but failing to get the commission to reopen the case, the environmental groups also went to the appeals court.

In the Vermont Yankee case, the appeal courts struck down the rulemaking proceeding as inadequate; in Consumers Power, it held the environmental impact statement fatally defective for failure to examine energy conservation as an alternative to the plants. Then Chief Judge David L. Bazelon wrote the opinions.

In overturning the appellate court, Rehnquist blasted it for "Monday morning quarter-backing" that "fundamentally misconceives" the nature of the judicial review required under the Administrative Procedure Act of 1948 and other laws.

"Nuclear energy may some day be a cheap, safe source of power or it may not," Rehquist wrote. "But Congress has made a choice to at least try nuclear energy, establishing a reasonable review policy in which courts are to play only a limited role."

Justices Lewis F. Powell Jr. and Harry A. Blackmun did not participate in the Supreme Court's decision.