Syria closed a key pipeline carrying Iraqi oil across Syria to Mediterranean ports today, leaving Baghdad with only one outlet for its vital oil exports, Iraq announced.

The Syrian move appeared to be a major blow to the Iraqi government of President Saddam Hussein at a time when foreign exchange is sorely needed to meet expenses of the 18-month-old war with Iran. It followed Syria's annoucement Thursday that it was closing the Iraqi-Syrian border because of alleged Iraqi support for Moslem Brotherhood rebels in Syria.

Syrian officials in Damascus described the pipeline shutdown as a "complement" to the border closure.

The 500-mile pipeline divides in Syria, with one branch extending to the Syrian port of Banias and another to the northern Lebanese port of Tripoli. It was estimated to have been carrying just under half of Iraq's petroleum exports of about 900,000 barrels a day.

The rest of Iraq's oil exports have been passing through another pipeline that goes to Turkey's Mediterreanean coast. This pipeline has been sabotaged several times by antigovernment rebels.

Iraq's major oil export facilities at the northern end of the Persian Gulf have been out of commission since the early days of the Iranian-Iraqi war in September 1980, when they were bombed by Iranian planes. Before the hostilities, Iraq exported about 3.4 million barrels a day, making it one of the major producers in the Organization of Petroleum Exporting Countries.