Representatives of the government and the leftist guerrillas of El Salvador met here last week on the initiative of Peruvian President Alan Garcia, a senior government official and local news reports said today.

It was the first formal encounter between the two warring sides in El Salvador's six-year-old civil war since a peace dialogue collapsed in November 1984.

News of the meeting was leaked to Lima's media by Peruvian government sources and confirmed at mid-morning by Foreign Minister Allan Wagner. No information was available on the substance of the conversations.

Wagner said the 10-hour meeting on Saturday was held at Garcia's private residence in the Lima suburb of Chacarilla and arranged by Garcia's staff. Garcia reportedly made only a brief courtesy call on the Salvadorans. Mediating was Peru's labor minister, Carlos Blancas.

The Salvadoran government was represented by Minister of Culture Julio Adolfo Rey Prendes, a close aide to President Jose Napoleon Duarte. The Democratic Revolutionary Front, the political arm of the Salvadoran guerrillas, was represented by Ruben Zamora, its second in command.

Wagner said Garcia invited the two Salvadoran sides to talk as a means of "seeking avenues to reopen dialogue in Central America." He did not say whether talks would continue.

A spokesman for the U.S. Embassy here said there was no connection between the meeting and the April 25 visit to Lima of special U.S. envoy Philip Habib, who also talked with Garcia. Habib was on a tour of nations participating in the Contadora peace talks in Central America and the so-called Support Group, which includes Peru as well as Uruguay, Argentina and Brazil.

The Salvadoran Embassy here did not issue any statement on the talks.

Since Garcia took office last July, his government has taken interest in seeking a peaceful settlement of the Central American conflict. In his inaugural address, he launched the Support Group in an attempt to revive and broaden the Contadora initiative.

Garcia has announced that he will go to Costa Rica for the inauguration of President-elect Oscar Arias on May 8. Wagner said that there would probably be a meeting of Latin American heads of state then to deal with the Central American peace initiative.

About 14 heads of state have confirmed their presence in San Jose, according to diplomatic sources in Lima.