The leaders of the major European allies, meeting at a Common Market summit here, decided tonight to publicly reaffirm their plan to impose tough economic sanctions against Iran if the American hostages are not released.

But, following the failed U.S. attempt to rescue the hostages, the diplomats here also discussed ways to convey privately to President Carter the Europeans' strong opposition to any other military action in Iran or the Persian Gulf, particularly without prior consultation with the allies.

French President Valery Giscard d'Estaing today hinted at the likely content of the joint public statement expected from leaders of the nine Common Market countries at the end of their summit here Monday. He told reporters that "France, with Europe, has decided to pursue its efforts in solidarity with the United States to obtain the release of the hostages within the framework of human rights and international law."

In Giscard's formal diplomatic language, this means continuation of the phased program of European economic and diplomatic sanctions against Iran and categorical disapproval of military or other measures beyond "the framework of international law."

Diplomats accompanying the European heads of government today discussed both an early summit meeting of the allied leaders with Carter and a scheduled visit to Washington next week by British Foreign Secretary Lord Carrington as possible vehicles for frank discussion of the Carter administration's relationship with the allies during both the Iran and Afghan crises.

However, the question of a special allied summit was not raised during the five hours that the heads of government spent discussing Iran, Afghanistan and other problems in the Middle East tonight, according to informed sources.

Carrington will not be given a formal mandate to speak for all the nine Common Market countries in Washington, these sources said, but he is likely to reflect their concerns. Allied leaders also are scheduled to meet with Carter at a Western economic summit June 22 in Venice.

Despite resentment in several European capitals about the timing of the U.S. military rescue mission -- just after the Europeans had agreed to imposed sanctions on Iran to forestall any military action -- an informed Common Market source said "there were no recriminations" during the summit talks tonight.

Concerned that the Europeans might change their minds about sanctions against Iran after the aborted rescue of mission, Deputy Secretary of State Warren Christopher met with allied ambassadors in Washington to ask their countries to go ahead with the measures.

"There was unanimous support for the position of the United States in its attempt to release the hostages unharmed and for Europe to adhere to the decision taken by the foreign ministers" of the Common Market countries last Tuesday to impose phased sanctions, according to a British source.

Other senior diplomatic sources here said today they believe the fate of the hostages and the credibility of the Western alliance depends on giving Carter strong support and avoiding criticism of the failed rescue mission. But they said they also would seek the best channel to communicate to Carter what one senior diplomat called "the consensus in Europe against any use of force, a concern that has been heightened in the aftermath of the aborted rescue attempt."

The rescue mission's timing and failure are expected to make it more difficult in a number of European countries, including Britain and Italy, to pass legislation enabling them to impose sanctions over growing opposition from left-wing opponents in their parliaments.

Diplomats here also said today that it complicates the job of their ambassadors to Iran, who leave Europe tonight to meet with Iranian President Abol Hassan Bani-Sadr this week for one last plea that the hostages be released before European sanctions are imposed.

Interest also has been expressed here in discussing with Carter widespread European irritation and concern about a series of recent tactical, communication and coordination problems between the United States and the allies, culminating in the mounting of the rescue mission even as the Carter administration was strongly pressing the allies to join in imposing sanctions against Iran.

European diplomats cite as earlier examples of drift and poor coordination:

The failure of Carter to inform the allies in advance that he had finally decided on a U.S. boycott of the Olympics.

His disavowal of the U.S. vote for a U.N. Security Council resolution condemning Jewish settlements in the Israeli-occupied territories.

His several earlier changes of mind on sanctions against Iran.

His lack of a viable strategy, in the view of Europeans, for dealing with the Soviet invasion of Afghanistan.

Both British and West German diplomats here expressed interest today in holding a summit meeting with Carter well before the Western economic summit planned for late June. But British sources also pointed out potential problems with such a summit, including the questions of Carter's willingness to go, the choice of who else would attend and the possibility of "the glare of publicity" focusing attention on and raising unreasonable expectations of solving the alliance's wide range of disagreements on political tactics for handling world crises.

In public, however, European leaders are trying to emphasize the distinction between the failed rescue mission and other kinds of military measures. In a supportive telegram sent to Carter today, West German Chancellor Helmut Schmidt expressed the understanding that "whoever has carried the responsibility of hostages' lives can feel with you at this moment."

This was a reference to the successful West German commando raid to free hostages from a Lufthansa airliner held by terrorists in Somalia in 1977, although that mission was carried out with the cooperation of Somali authorities.