The war between Iraq and Iran will have the immediate effect of removing about 3 million barrels of oil a day from the world market, in the view of oil industry experts, and, if it spreads, could disrupt all exports from the Persian Gulf region, where nearly half of the Western world's oil is produced.

Yesterday's bombing raids and artillery attacks reportedly have halted all exports from the two countries except for a portion of Iraq's production that is sent out of the country by overland pipelines.

In addition, heavy damage to refining facilities in both countries, including the Iranian refinery at Abadan, the world's largest, are expected to have a long-term effect on exports.

One U.S. oil company official noted that for the first time Middle East hostilities have caused significant damage to oil producing and refining facilities.

"They would shoot each other, but not damage the oil fields, because they knew their future depended on it after they had picked up all the bodies," this source said.

While the world currently enjoys a considerable oil surplus -- a situation that led members of the Organizations of Petroleum Exporting Countries to move toward a 10 percent production cutback last week -- analysts said yesterday that the unexpected Iraq-Iranian war could drain the world glut within months.

Only a small portion of American oil imports come from Iraq, whose oil is sold largely in Western Europe. But Kuwait, which abuts the fighting zone, and the other countries that ship their oil through the vulnerable Strait of Hormuz in the Persian Gulf provide 75 percent of Japan's oil and about half of Western Europe's.

Away from the immediate area of the fighting at the northern end of the Persian Gulf, American oil companies reported, shipping appeared to be unaffected although it was proceeding cautiously.

An Iranian broadcast warned ships entering the Persian Gulf to steer clear of Iran's coastal waters and Reuter reported that an Iranian naval statement said that country would not "give authorization" to any ships headed for Iraqi ports.

The U.S. government broadcast an advisory Monday night warning American vessels in the area to avoid Iranian waters and the Iraqi coastline.

British sources said in London that Britain had advised its vessels not to enter the Persian Gulf for the time being and if they were in it, not to attempt to leave. An Agence France-Presse report from Manama, Bahrain, said 30 supertankers were at the entrance of the Strait of Hormuz, apparently waiting for hostilities to cease before entering the gulf.

Lloyds of London and the Institute of London Underwriters, the major insurers of oil vessels, yesterday raised their rates for coverage of cargo being shipped to and from Iran and Iraq to a level that one oil company official described as "prohibitive" -- a move that insurance sources in London said could lead many shippers to reduce or suspend activities for the time being.

The basic war-risk insurance rate set yesterday for the two countries was 0.5 percent of the total value of the cargo, and many underwriters add surcharges to that amount, sources in London said.

The amount of oil removed from the market by a shutdown of Iraqi and Iranian exports is about one-tenth of OPEC's total production of 27 million barrels a day, but Iran's exports in recent months have plummeted and have gone primarily to Eastern Europe.

Before the overthrow of the late shah, Iran was the world's second largest exporter, shipping about 6 million barrels a day, but in recent months, with its production and refining systems in disarray, it had been exporting only about 500,000 barrels a day.

Iraq produced about 3.5 million barrels a day, keeping only a small portion for its domestic needs and exporting the rest. About 2.2 million barrels daily were being shipped through the gulf and 800,000 barrels passed to the Mediterranean through pipelines crossing Syria and Turkey. While vulnerable, the pipelines reportedly have not been affected by the fighting.

U.S. Deputy Energy Secretary John Sawhill, testifying at a Senate hearing Monday, said that a halt in exports by the two countries would have a insignificant effect on supplies to the United States if the cutoff were not lengthy and did not spread.

The Iranian refinery at Abadan, which reportedly was seriously damaged by Iraqi raids yesterday, is the world's largest, with a capacity of more than 600,000 barrels a day. In recent months, however, its output had dropped to a fraction of that and the facility reportedly was being used primarily to store heavy crude oil that Iran was having difficulty selling at the high prices the revolutionary government has set.

Abadan is also one of the world's oldest refineries. Its first facility was opened in 1909 by the Anglo-Persian Oil Co. By 1950 it was the world's largest but it was surpassed by Ras Tanura, the biggest Saudi refinery, until Abadan was again expanded by the late Shah shortly before his overthrow.

The sudden cutoff of exports from Iran and Iraq and the threat of a greater disruption in the region come as the world has been enjoying an unaccustomed surplus of oil.

The 1973 Arab oil embargo and the 1,500 percent increase in prices since then have had enough of a braking effect on consumption by the industrialized countries that a glut equivalent to several months' needs has developed.

At the meeting in Vienna last week of OPEC oil ministers, the petroleum producing countries reflected this change situation by avoiding another major price increase and, instead, with some members agreeing informally to work to reduce output by up to 10 percent.

Yesterday, it was reported that two big oil companies in the Washington area -- Texaco and Sunoco -- have begun giving rebates of up to 7 cents a gallon to service station owners who maintain high sales volumes in the face of what has become a nationwide gasoline glut.