The United States and West Germany may be heading into another controversy over security issues similar to the episode over neutron weapons last spring that brought hard feelings and political embarrassment to both Bonn and Washington.

The issue this time is how the West should respond to the buildup of mobile, multiple-warhead Soviet SS20 medium-range missiles targeted on Western Europe.

The Bonn government, along with the rest of the NATO alliance, would prefer that these weapons be negotiated out of existence in the U.S.-Soviet strategic arms talks. If that cannot be accomplished, however, new U.S.-developed weapons such as improved, nuclear-tipped versions of the medium-range Pershing missile or cruise missiles may have to be based in West Germany to counter the Soviet weapons.

That prospect presents a two-fold problems. Positioning those weapons in West Germany would mark the first time that nuclear weapons able to reach the Soviet landmass were stationed in West Germany. This would undoubtedly subject Bonn to a rash of Soviet verbal attacks at a time when the two countries generally have been improving relations.

Secondly, while Bonn has made clear it would go along with any joint NATO decision on modernizing nuclear weapons based in Europe, Bonn has also informed Washington and NATO that West Germany will not allow itself to be the only West European country where such weapons are based.

This sets up the potential for a repeat of the neutron weapon flap -- just as the West Germans were finally signaling their willingness to accept the controversial weapons, President Carter decided against producing them for the time being.

According to some military analysts here, West Germany is the only spot where these weapons could reasonably be based. France, which is outside the NATO military alliance, and Britain have their own medium-range nuclear strike forces. And it would be politically impossible to place new atomic arms in the Netherlands or Belgium. Besides neither country is in the proper geographic location.

"West Germany cannot expect its American partner to contribute more to our security than we are ready to contribute," wrote the military specialist in the influential Frankfurter Allgemeine newspaper this week. "Chancellor Helmut Schmidt's argument that modernized nuclear weapons should be stationed not only on pretext for not wanting to take over responsibility. Where should these weapons be stationed? They should be stationed where the allied forces are," meaning here, the article said.

"For two decades we have implored the Americans to maintain their military presence... and now the nuclear arsenal for supporting them should be stationed elsewhere? he asks.

The matter, however, is extremely delicate since Bonn is not a nuclear power and does not want to be considered one, even though the atomic warheads would remain in U.S. control.

Politically, the issue also carries some danger at home for Schmidt. This week, the powerful leader in parliament of Schmidt's ruling Social Democratic Party, Herbert Wehner, startled many West Germans by a free-wheeling newspaper interview in which he described the Soviet military buildup as basically defensive.

Wehner, 72, is a prewar Communist who eventually helped lead the postwar Social Democrats away from Marxist policies. He is, however, a major figure on the left wing of Schmidt's party and is not especially warm to the United States.

Wehner's description, which was viewed as reckless by conservative opposition parties and even by some Social Democrats, is interpreted by some political specialists here as an attempt to keep the arms debate in balance and not to let the momentum to install additional arms overcome the effort to negotiate arms control agreements. His remarks, however, are also seen as meant to disuade Schmidt from damaging the general policy of maintaining good relations with Moscow.

The chancellor, however, is generally much more conservative than Wehner, and on the issue of national security Schmidt has his own very high popularity plus the support of the conservatives and many within his own party to back him. Thus, Schmidt is able to override pressure from the left.

Senior West German officials believe that there are alternatives to stationing new weapons solely on German soil, although they do not at this point say where that might be.

Bonn officials argue that the big difference between the current debate and the neutron weapon debacle is that allied consultations are going on in the NATO nuclear planning council to try and thrash out these issues before it is time for the political leaders to take a stand publicly.

It is those deliberations that they are hoping will avoid a repeat of last year's hard feelings.