Iranian warplanes bombed Baghdad yesterday for the first time in three days as Iran stiffened its defense of cities under attack by Iraqi forces.

Diplomatic efforts toward a cease-fire stalled, and Ayatollah Ruhollah Khemeini, in a late-night broadcast, said Iran would consider a halt to the fighting with Iraq "only if they surrender."

The Iranian raids damaged auxiliary buildings at Iraq's most important nuclear facility, which apeared to be the chief target, and blew up a large fuel storage tank at a major Baghdad electrical power generating plant, according to Western sources.

The $300 million, French-built nuclear research center suffered only minor damage, according to French officials in Baghdad and Paris, and the reactor itself was not hit. More than a dozen Iraqis were killed in the bombing of the electrical plant, news services reported.

As Iran resumed its raids on the Iraqi capital, it became apparent that Iraq's claims in recent days of capturing major western Iranian cities were exaggerated. Reporters approaching Ahwaz from the Iraqi side found heavy fighting under way more than 15 miles from that Iranian provincial capital, and a Japanese diplomat leaving Khorramshahr, another city Iraq claimed to control, said he had seen no Iraqi soldiers in the city although it had come under heavy fire.

Diplomatic efforts to halt the fighting appeared to be at a standstill.

U.S. Secretary of State Edmund S. Muskie met in New York with Iraqi Foreign Minister Saadoun Hammadi and said he repeated the U.S. position that the war halted. Iran said it would respond today to the U.N. Security Council's call for a cease-fire.

Pakistani President Mohammad Zia ul-Haq, who had been shuttling between Tehran and Baghdad in a peacemaking effort, flew to the United Nations and, during a stopover in Paris, gave no indication of progress.

Soviet President Leonid Brezhnev, in his first public comments on the war, called on Iraq and Iran to start negotiations on a settlement and, in a clear criticism of the United States, said that "some people are obviously trying to turn that conflict into their profit."

In Iran, meanwhile, the parliament approved a seven-member commission to investigate the issue of the 52 American hostages held since Nov. 4, according to Tehran radio, and put off further action until Sunday.

The Iranian raids on Baghdad came about 1 p.m., shortly after Zia and Iraqi President Saddam Hussein had concluded their talks and Zia, chosen by the Islamic Conference for the peace mission, had left for Paris.

The nuclear research center attacked by Iran's U.S.-made F4 Phantoms has long been a controversial facility, with Israeli and some Western experts expressing fears that, with French supplies of highly enriched uranium fuel, Iraq could build an atomic bomb within a few years.

Equipment and technicians associated with the Iraqi nuclear plant have been targets of unidentified attackers in France. In April 1979, saboteurs broke into a warehouse in France and blew up the core of the reactor before it could be shipped to Iraq. Three months ago, a top Iraqi nuclear scientist was machine-gunned to death in Paris.

France has contended that the joint project with Iraq is for peaceful purposes and that the enriched uranium it is delivering would be internationally monitored to prevent its misuse.

According to Agence France-Presse, sources in Paris said that only four to six pounds of highly enriched uranium had been delivered to the facility and French nuclear experts were reported as saying that there was no danger of a radiation leak from a successful bombing until the reactor in in operation.

A spokesman for the French Atomic Energy Commisssion said in Paris that all but about 50 of the 400 French technicians and other workers at the facility had already been evacuated from Iraq. Several buildings, including housing for some of the workers, were damaged, French officials in Baghdad said, but there were no injuries.

The direct hit on the oil storage tank at the electrical power station in a raid by three low-flying Iranian F4s was the most devastating bombing attack yet in the Iraqi capital. The vast fire could be seen in much of the city and sources told Associated Press that at least 10 persons were killed and 85 injured.

Reuter reported from Tehran that Iranian military leaders pledged to achieve "final victory" against Iraq as heavy fighting continued in Khuzestan, Iran's major oil province.

Khomeini, in a broadcast speech, told Iranians that their troops would press the war against Iraq "and crush them all." He said Iran "will not negotiate with them at all because they are corrupt. Only if they surrender, for the sake of Moslems, we might consider something." He did not specify what.

Although Iraqi forces remained deep in Iran -- as much as 60 miles in places -- Iranian defenders, including units of the Revolutionary Guard, appeared to be holding the important cities.

Residents of Ahwaz, reached by Reuter by telephone from Tehran, said that provincial capital was calm and in Iranian hands, although Iraq, for several days, has claimed to be on the verge of capturing it.

The Japanese Foreign Ministry said that is consul general and two staff members had left Khorramshahr, a key Iranian port city at the head of the Persian Gulf, after shell splinters landed in the compound of the official residence. But the envoy reported that no Iraqi troops had been seen in the city.

Iraq's military command announced, meanwhile, that its aircraft destroyed three bridges each of Dezful, a refinery city 50 miles from the Iraqi border, in a move intended to cut off retreat by Iranian troops.

Brezhnev, speaking at a state dinner for visiting Indian President Sanjiva Reddy, sharply condemned the United States, accusing it of encouraging the Persian Gulf war, but he offered no Soviet intiatives to end it nor threats to intervene it if is not, Washington Post correspondent Kevin Klose reported from Moscow.

Without mentioning the United States, Brezhnev said, "Some people ar obviously trying to turn this conflict to their profit. The are those who want to establish their control over Middle East oil, who again dream of turning Iran into a military base and gendarme post of imperialism."

He said, "Neither Iraq nor Iran will gain anything from mutual destruction, bloodshed and undermining each other's economy. It is only the third side that stands to gain."