NICOSIA, Cyprus (AP) _ Iran said Sunday its warplanes attacked an Iranian rebel base deep inside Iraq. Baghdad claimed one of the eight U.S.-built fighter-bombers was shot down and its two-man crew captured.

Tehran said the air strike was in retaliation for a raid by the rebels of the Mujahedeen Khalq, or People's Holy Warriors, on two villages in western Iran Saturday.

The air raid marked a sharp deterioration in relations between Iran and Iraq, which still have not signed a peace treaty to formally end their 1980-88 war.

A U.N. spokesman, Boris Holtzman, said neither country had filed any statement or protest before the world body by midday Sunday.

Iraq reported earlier that eight Iranian F-4 fighter-bombers raided a Iranian rebel base north of Baghdad, and that Iraq shot down one warplane and captured its two crewmen.

The Iranian rebels said one of their fighters, Hossein Nikpeiman, was killed and several others were wounded when the base was showered by cluster bombs in five Iranian sorties.

The rebels said the target was their base at Khalis, deep inside Iraq and just 40 miles from Baghdad, the capital.

State-run Baghdad radio, monitored in Cyprus, called the raid an act of ''blatant and unjustified aggression.''

''Iraq warns the reckless Iranian regime of the consequences of this impudent, aggressive act and holds it fully responsible for the grave consequences,'' the radio said.

''Iraq also reserves its rights concerning this aggression.''

The Mujahedeen Khalq is the largest exiled Iranian opposition group. It's military wing, the National Liberation Army, operates several military bases inside Iraq.

Mujahedeen Khalq identified the captured fighter pilots as Sgt. Arsalan Sharifi and Sgt. Qassem Amini, both from the Hamadan air force base in western Iran. It was not immediately known whether they were injured.

The group said the wreckage of the downed aircraft was inside its base.

Tehran said the air strike was in retaliation for rebel attacks Saturday evening on two villages in western Iran.

Iran's official Islamic Republic News Agency, monitored in Cyprus, said the attackers killed several villagers and abducted a number of others. It did not name the villages, but said they were near the Iranian border town of Qasr-e- Shirin.

The Mujahedeen denied carrying out the raids. The group has stepped up its verbal attacks on the Iranian government, at a time when Iran is preparing for parliamentary elections this week.

The elections have ruined the precarious balance between the pragmatic and radical factions ruling Iran, as President Hashemi Rafsanjani's government tries to sideline its stubborn hard-line opponents ahead of Friday's vote.

Iran and Iraq fought an eight-year war that ended in August 1988.

The Iraqi Foreign Ministry sent a note to U.N. Secretary-General Butros Butros-Ghali complaining against the ''Iranian aggression,'' the radio said.

The Iranians are believed to have about 20 American-made F-4s in working condition. The rest have been grounded because of a lack of spare parts, which the United States officially has refused to sell them since Iran's anti- American Islamic revolution in 1979.