BONN, AUG. 4 -- The European Community, West Europe's main trade bloc, and the East European economic organization Comecon are likely to establish formal relations by the end of this year and end three decades of mutual nonrecognition, EC officials say.

The expected move, under discussion for the past year, would make it easier for the 12-nation EC to negotiate trade accords and other agreements with individual European Communist nations.

The rapprochement reflects increased European interest in intensifying East-West economic cooperation and is a result of the more flexible diplomatic approach toward West Europe adopted by Soviet leader Mikhail Gorbachev, according to EC officials and other western analysts.

The U.S. administration, which has been skeptical in the past of West European desires for trade with the Soviet Bloc, has taken a cautious attitude toward the EC-Comecon discussions, U.S. officials said.

Comecon, or the Council for Mutual Economic Assistance, groups the seven East European nations of the Warsaw Pact plus Vietnam, Cuba and Mongolia. It was founded in 1949.

Washington is concerned that the EC might bolster Comecon's diplomatic status, give up more to the East economically than it receives or drive a wedge between the EC and the United States over the issue, they said.

"We can't stop them {the EC}, and we're not trying to stop them, but we have warned them to watch out," a senior U.S. official said.

EC External Relations Commissioner Willy de Clercq has acknowledged the U.S. concerns but says the EC is "not going starry-eyed over a brave new dawn.

"Our commercial exchanges will be based on the principle of effective reciprocity. We are not in the business of handing out free gifts," de Clercq said last month in a speech at an EC conference in Copenhagen.

Nevertheless, de Clercq said, formal relations between the two organizations could help open the East European market to EC countries and eventually lead to increased acquisitions of western technology by the Soviet Bloc. Currently, only 7 percent of EC trade is with Comecon countries.

"If we want to exploit that market, it means that it is in our interest, together with their own reform efforts, to contribute to their industrial and technological development," de Clercq said. "Improved trade could also, in a more general way, improve the climate of relations between Eastern and Western Europe."

De Clercq indirectly criticized the American government's stance: "I sometimes feel that some Americans look at Eastern Europe from such a distance that they are only able to distinguish black and white. Here, at close quarters, we can see all the various shades of gray. This, in my view, makes for a more balanced and pragmatic attitude toward Eastern Europe."

The EC and Comecon have had two rounds of talks on opening official relations and have tentatively agreed to issue a joint, high-level declaration that would signify mutual recognition.

The only remaining obstacle concerns the status of West Berlin. Comecon has so far rejected a clause that effectively means West Berlin is a part of the EC -- a dispute that has arisen in previous EC dealings with individual East European states. As a result of earlier successes in dealing with that issue, EC officials expressed confidence that an accord with Comecon will be reached during 1987.

The Soviet Union and its East European allies virulently attacked the EC when it was founded in 1957. Communist officials described the EC as a capitalist, imperialist organization and the economic arm of NATO.

The Soviets and their allies have sought consistently in United Nations agencies and other international organizations to prevent the EC from representing West European countries.

In the era of East-West detente in the early 1970s, the Soviets relaxed their position somewhat. Talks on recognition began then between Comecon and the EC, but they were broken off in 1982 because Comecon insisted on being treated as a trading bloc equivalent to the EC.

The European Community argues the opposite, maintaining that Comecon does not negotiate for its members on trade issues as the EC has done since 1973. The EC, like the United States, also does not want to help Comecon too much because the West views Comecon as a Soviet lever to exert economic pressure over its smaller allies.

Under Gorbachev, the Soviets have dropped their insistence that Comecon be treated as equivalent to the EC. Comecon has now accepted what the EC calls its "parallel approach," under which the EC negotiates trade agreements with individual Comecon members rather than with Comecon as a whole.

The EC currently is negotiating expanded trade agreements with Romania, Czechoslovakia, and Hungary and is exploring new accords with Poland and Bulgaria.

Some of these countries have been reluctant to sign the new agreements, however, until Comecon and the EC establish formal relations.