When Gen. Efrain Rios Montt tried to introduce a sales tax here in the summer of 1983, the idea was so unpopular that it contributed to his being ousted from power in a classic palace coup.

His successor as military ruler, Gen. Oscar Humberto Mejia Victores, tried to impose a similar tax last week, and it quickly prompted talk among some Army officers of a plot to throw him out as well. The coup failed to materialize this time, however, and Mejia, although embarrassed and weakened, has for the time being retained his office in Guatemala's gingerbread presidential palace.

According to Guatemalan political leaders, the coup that wasn't provided a promising measure of the changes under way in what long has been criticized as Central America's most chronically unstable and brutal country. The outcome also pleased the Reagan administration, whose request for $10.3 million in military aid would have been compromised in Congress by yet another violent change in military governments.

"It was a political victory," said Jorge Carpio Nicolle, a centrist presidential candidate for elections scheduled Oct. 24. "This showed that military authority is no longer absolute."

Mejia, instead of forcing the taxes on an outraged public through military might, backed off and rescinded his orders. Carpio said the general also promised to create a commission including business and political leaders to devise a more acceptable way to meet Guatemala's increasing pressing economic problems.

At the same time, coup-prone Army officers, strongly courted by disgruntled business and political figures, were unable to organize enough support among fellow officers for a move against Mejia. The military's main concern, Guatemalan and diplomatic sources said, was to prevent further tarnishing of the country's image at a moment when Latin America has begun to pay increasing homage to democratic rule as an ideal if not always a practice.

In addition, diplomatic sources pointed out, few officers wanted to take charge of the country at a moment when painful economic measures of some kind seem inevitable even if Mejia's plan has been rejected for now.

Even Mario Sandoval Alarcon, whose right-wing National Liberation Movement has a history of cooperation with Guatemalan military dictators, condemned the idea of a coup d'etat as "in no way appropriate in these times."

"It would affect the democratization process under way and damage even more the bad image Guatemala has abroad and that the present government has been unable to change," he said in a statement.

Mejia, who pushed out Rios Montt on Aug. 8, 1983, has paid his own homage to the democratic ideal by pledging to turn over power next January to the winner of October's presidential elections. The turnover, if it takes place as scheduled, will mark a formal end to military rule that has lasted here, directly or indirectly, since a takeover organized by the Central Intelligence Agency in 1954 to get rid of an elected government that Washington judged dangerously leftist.

Most Guatemalan political leaders and foreign diplomats, however, expect the Army to maintain a large measure of power, particularly in national security matters, even if the elected government takes office as promised. This would correspond to a pattern set by two other recent converts to civilian government in the region, Honduras and Panama.

Vinicio Cerezo, presidential candidate of the moderately leftist Christian Democratic Party, said assumption of effective power by a civilian president in Guatemala must be a gradual evolution, given the country's history. But, he added, Mejia appears sincere in his promises to get the Army out of the formal business of government. In addition, he noted, the Army's reaction to the tax uproar ended as a political retreat rather than the show of force that Guatemalan tradition would have dictated.

"Gen. Mejia is beginning to convince me that he really wants to hand over power," Cerezo said in an interview.

The coup talk occurred with tension already high over a series of Easter season killings in Guatemala City that underscored anew the country's reputation for brutality. Guatemalan political sources speculated that one killing, that of a retired general and his 3-year-old grandson, might have been carried out because of the clandestine maneuvering against Mejia.

The others, however, appeared aimed at stifling a human rights pressure group whose emergence was cited to Congress as a promising development in the U.S. Embassy's 1984 human rights report. The group, Mutual Support, embraces more than 600 relatives of Guatemalans who have disappeared in what their families say is government-sponsored repression. It is the first such organization to spring up here in five years because of what activists say is fear of government retribution.

One of the group's six executive committee members, Hector Orlando Gomez, was kidnaped by armed men March 30. His body was found the next day with his tongue cut out.

Another leader, Maria del Rosario Godoy de Cuevas, spoke bitterly of human rights violations at Gomez's funeral a few days later. On Good Friday, she, her 21-year-old brother and her 3-year-old son were found in the morgue after what authorities called an auto accident. Archbishop Prospero Penados del Barrio called it a "triple assassination."

Since then one committee member has fled to Mexico. The remaining two have been permanently accompanied by unarmed foreign escorts to reduce the danger of attack.

One of the two, Nineth Montenegro de Garcia, suggested Mejia had contributed to the atmosphere that makes such murders possible by saying in a speech March 15 that Mutual Support receives backing from "subversives."