President Anwar Sadat's National Democratic Party was headed toward victory yesterday in the first multiparty Egyjtian election in 27 years.

Projections based on initial results indicated the party could take 84 percent of the vote, giving it 321 of the 382 contested seats in the next parliament. Sadat appoints a further 10 members.

Runoff elections are scheduled for Thursday but several close associates of Sadat already were pronounced winners, including Prime Minister Mustafa Khalil, Justice Minister Ahmed Ali Moussa and Interior Minister Nabani Ismail.

Losing candidates included several members of the leftist National Unionist Progressive Rally led by Khaled Mohieddin - one of several parties opposed to Sadat's peace treaty with Israel but prevented by law from campaigning on that issue.

In other Middle East developments;

Israeli warplanes and artillery attacked Palestinian guerrilla bases in southern Lebanon for the first time in 16 days. Three guerrillas were reported injured.

An Arab councilman in the West Bank town of Rujeb, near the new Israeli settlement of Elon Moreh, called creation of the outpost "an act of strangulation" that could ignite violent protests in the Israeli-occupied region. The settlement established Thursday was the first since the signing of the Egyptian-Israeli peace treaty.