The European Community, in a strongly worded formal protest to the Reagan administration today, attacked U.S. sanctions against the projected Soviet gas pipeline as violations of both international and American law and predicted they would backfire on two fronts.

Unless the latest U.S. restrictions are lifted, the European governments warned, trade relations between the United States and its European allies will be damaged "unquestionably and seriously" and the Soviet Union will be encouraged to step up its own manufacturing potential to complete the pipeline on time.

These claims were forcefully spelled out in a note that accompanied a detailed, 14-page list of legal arguments against President Reagan's June decision to extend the prohibition on the use of U.S.-developed technology in the planned pipeline to European subsidiaries of American companies and to holders of U.S. licenses.

The 3,500-mile pipeline will carry natural gas from Siberia to Western Europe. The project will cost about $10 billion and involves billions of dollars in contracts with Western European companies.

The statement was approved by all the European Community governments.

The State Department acknowledged receiving the protest and said it was being studied, Reuter reported in Washington. A spokesman said the protest note had been expected as part of normal procedures.

"The European Community considers the U.S. measures contrary to international law, and apparently at variance with rules and principles laid down in U.S. law," the statement said.

The extraterritorial reach of national regulations has been a disputed issue in European courts for some time. But Western European leaders clearly regard Reagan's decision as an affront to national sovereignty. They also object to its retroactive application to signed contracts.

U.S. officials have argued that European companies participating in construction of the pipeline and relying on U.S. licenses signed contracts long before the Soviet deal was negotiated, binding them to respect American law regarding the export of sensitive U.S. technology. But European officials maintain that this promise to abide by U.S. law held only until contracts for the reexport of goods for the pipeline were signed with the Soviets last fall.

Beyond the legal arguments, the European governments said in their joint statement, "It is unlikely the U.S. measures will in fact delay materially the construction of the pipeline or the delivery of the gas. The pipeline from Siberia to Western Europe can be completed using Soviet technology and production capacity diverted from other parts of their current program."

The technology ban has hit $3 billion worth of contracts between the Soviet Union and firms in Britain, France, Italy and West Germany at a time of economic difficulty in Europe and sharp U.S.-European policy differences over the use of trade generally as a political lever in East-West relations.

Britain, France and Italy have instructed firms in their countries to ignore the American ban, while West Germany, reluctant to go quite as far without the domestic legal instruments that are available to the others, has promised political and moral support at least for companies fulfilling pipeline contracts.

On Monday, West Germany's AEG-Telefunken, the insolvent electrical giant, announced that it would go ahead with September delivery of the first two compressor turbines ordered by the Soviets. The machines contain rotor blades made by General Electric and covered by Reagan's ban.

"The recent U.S. measures," the protest note said, "provide the Soviets with a strong inducement to enlarge their own manufacturing capacity and to accelerate their own turbine and compressor developments, thus becoming independent of Western sources."

While U.S. officials have predicted that the embargo could delay the project by up to two years, the Europeans pointed out that this would not prevent Moscow from selling new gas to Western Europe exactly on time.

"Gas could still flow to the community starting as scheduled in 1984," the Europeans' statement said, "owing to the existence of substantial spare capacity in the existing pipeline system, sufficient to cover the requirements of the early phases of the program of deliveries."