Britain and the United States agreed today on a framework accord setting forth the terms for participation by British companies in the Reagan administration's Strategic Defense Initiative.

If approved by leaders of both countries, the document will become the first government pact linking the United States with one of its allies in the planned $26 billion research program for a space-based missile defense system.

The draft agreement is expected to serve as a precedent for other allies, particularly West Germany and Italy, who have awaited the outcome of the British-American negotiations before seeking to conclude their own deals with the United States in order to ensure a satisfactory distribution of new technologies and research contracts.

The details of the accord were sealed at a meeting here today of Secretary of Defense Caspar W. Weinberger and British Defense Minister Michael Heseltine, following a nuclear planning session of North Atlantic Treaty Organization defense ministers.

In consenting to the agreement, Heseltine dropped an earlier British demand for a guaranteed $1.5 billion share in SDI research contracts. In return, he said, Britain received firm assurances that the "scale or content of its work" allotted under the plan would be commensurate with its leading position in several industries pertinent to missile defense technology.

The Reagan administration believes such government accords could solidify the backing of allies for the controversial SDI program, which the Soviet Union contends is the chief obstacle to future arms control treaties.

The European allies are more concerned with gaining a proper share of lucrative contracts and sufficient access to research findings to keep pace with new technological developments that could radically affect their economies.

Before leaving for Washington, Weinberger told a press conference that the allies concurred with President Reagan's view that SDI "should not be negotiated away" at the Geneva arms talks.

Other ministers said, however, that the frequent expressions of allied support for research into space-based missile defenses should not be construed as advocating SDI's exemption from the Geneva negotiations.

"We are told that everything is on the table at Geneva, including space and defense systems," said Norway's Anders Sjaastad, who said Weinberger's comment did not foreclose possible "agreements which could certainly affect the development and deployment of SDI systems."

The public display of harmony was enforced by a general will to show "full support and solidarity" for Reagan, as stated in a communique, as he prepares for Geneva talks with Soviet leader Mikhail Gorbachev on Nov. 19 and 20.

The final declaration issued by the defense ministers endorsed the U.S. positions at the Geneva talks on space and nuclear weapons and denounced recent Soviet proposals as "one-sided and self-serving."

U.S. diplomats say a signed cooperation pact on SDI between the United States and Britain would be a welcome demonstration of allied support before the Reagan-Gorbachev talks.

But Heseltine said it was too early to tell whether the final review by both governments would permit the accord to be signed before the summit. He defended Britain's retreat from its insistence on a specific financial bounty for SDI contracts by saying the uncertain budget outlook in Congress meant that a fixed value in the SDI program could not be assessed for one country's contribution.

The United States had objected to the British demand by emphasizing that West Germany and Italy would likely follow suit in asking for guaranteed contracts even before much of the SDI funding has been approved by Congress.

Heseltine said he was satisfied that the written assurances given in the still-secret agreement and Britain's advance lead in certain SDI technologies would not short-change British participation.

The importance of the agreement, he said, is that it offers Britain "ambitious opportunities in the fields of tomorrow's technology."

Weinberger said that "the assurances for a leading role come from the expertise" shown by certain sectors of British industry. "I have no doubt that major contracts will be won by British firms," he said.

The British-U.S. accord cites 18 areas where Britain appears capable of making significant contributions to the SDI research program. Electromagnetic rail guns, space sensors and switching devices are some of the relevant fields of research led by British firms.