President Reagan has decided to blacklist an American multinational firm from export transactions if, as expected, its compressors for use in the Soviet-Western Europe natural gas pipeline are loaded onto a Soviet ship in a French port in defiance of a U.S. embargo, according to a well-placed administration official.

"The sanctions will be enforced," White House spokesman Larry Speakes said of the developing confrontation over the pipeline shortly before Reagan left here by helicopter for two weeks of vacation on his secluded ranch near Santa Barbara.

Speakes declined to say what specific actions would be taken. But administration sources said shipment of pipeline compressors by Dresser France, a subsidiary of Dresser Industries of Dallas, would be followed swiftly by U.S. action to deny one or both firms permission to export goods or technology from the United States.

Dresser France has been instructed by the government of France to make the shipment, in defiance of the embargo against such pipeline transactions ordered by Reagan.

Speakes' remarks and a similar statement in Washington by State Department spokesman John Hughes reflected what another administration official said was Reagan's "clear determination" to stick to the embargo. Reagan originally imposed it on U.S. firms last December and extended it June 18 to both overseas subsidiaries of U.S. firms and overseas firms using U.S. technology. Reagan acted in retaliation for Soviet-influenced repression in Poland.

One administration official said today the United States is likely to pursue both diplomatic and legal efforts in its attempt to force continued imposition of the sanctions. The diplomatic effort, which may involve a special U.S. mission to Europe, would be aimed at convincing France and other European nations that the pipeline is detrimental to their long-term interests. American diplomats have failed in earlier efforts to persuade the Europeans of this.

The State Department is reported to be resisting any idea of taking action against the French government, for fear of creating an even more serious split in the Atlantic alliance. However, one official here said U.S. diplomats have quietly suggested to the French that the United States might delay transfer of some unspecified high technology items to France if Dresser France is forced to deliver the compressors to the Soviets.

Administration sources said U.S. penalties against Dresser would be announced shortly after the shipment of compressors takes place at the French port of Le Havre. There were suggestions that in the eyes of U.S. lawyers the shipment will be made when the compressors are loaded aboard a waiting Soviet freighter, even if the ship remains in port for some time. But this was not completely clear.

Whatever happens in the Dresser case, an administration offical emphasized that Reagan intends to keep the pipeline sanctions in force unless there is "real evidence of constructive action in Poland."

This official described the sanctions as a human rights issue. He said that Reagan believes the Russians are using "slave labor" to build the pipeline and that this ultimately will become apparent to U.S. allies in Europe despite their present insistence that contracts supplying material for the pipeline be fulfilled.

The official also depicted the president as optimistic that his policy eventually will succeed despite the furor in Europe and the serious strain in transatlantic relations it has caused. According to an evaluation recently given the president, Soviet "inefficiency" and a predicted decrease in European natural gas demand are likely to delay construction of the pipeline even without the sanctions.

The Reagan administration strategy appears to be to keep up the pressure on U.S. allies and on firms supplying the material in the hope of delaying the pipeline as long as possible if it cannot be blocked completely. Administration officials believe that a show of firmness in the Dresser case will discourage other firms, particularly the British company John Brown Engineering Ltd., from also supplying pipeline material to the Soviets.

The president, accompanied by White House chief of staff James A. Baker III and national security adviser William P. Clark, departed for his Santa Barbara ranch today after two days of politicking for Republican candidates in Los Angeles. Officials said Reagan is not expected to make any more political appearances until he leaves the ranch Sept. 7.