This tiny, oil-rich republic on the Pacific held its first national elections in 10 years yesterday, joining Peru and Bolivia as the third South American nation within the past month to start converting a military form of government to a democratically elected one.

Although Ecuador's military junta, headed by Rear Adm. Alfredo Poveda, prohibited three potential candidates from running for the presidency, none of the vote-counting irregularities that marred Bolivia's recent election were expected her.

Indeed, there was the feeling that Ecuador's military leaders wanted yesterday's election to proceed smoothly and efficiently. It was somewhat unclear, however, when a run-off election would be held if none of the six presidential candidates receives a majority of the vote, as is expected, and when the eventual winner would assume office.

There were few election-day problems reported as Ecuador's more than 2 million voters, ranging from wealthy, finely dressed men and women here in butling Quito who have benefited from their country's recent prosperity, to impoverished laborers in the steamy port of Guayaquil who have benefited hardly at all, lined up at thousands of polling places throughout the country to chose among the six candidates for president.

Also at stake were hundreds of provincial and municipal offices. A new congress will be elected next year as part of a step-by-step return to democracy outlined by the military, which ousted Ecuador's last elected president, Jose Valasco Ibarra, in 1972. Velasco, who served as president five times, was last elected in 1968 and assumed dictatorial powers in 1970.

While Ecuadorians seemed interested in and expressed favorable feeling about yesterday's election, no one here thinks he has seen the last military coup. "The people aren't really prepared" for democracy, said Alexander Montano, 33, as she stepped from a polling table at the San Andres School in the heart of Old Quito. "I people than the military but I fear we need more preparation [for democracy], like other developing countries."

It is generally expected here that when the votes are counted today that Sixto Duran, a 57-year-old United States-born architect who was mayor of Quito until earlier this year, will emerge as the top vote getter - but without the 50 percent plus one vote necessary to be elected president without run-off election.

Duran is a right-of-center candidate, although he has said his goal is to transform Ecuador into a socialist, democratic state like Sweden. He is thought to be the favorite of this country's military leaders who, unlike their counterparts in Bolivia, were clever enough not to admit their preference publicly and risk an antimilitary reaction against their candidate.

One of three other candidates is expected to come in second and then face Duran in the run-off election: Jaime Roldos, 37, a lawyer who heads the populist Concentration of Popular Forces, or Rodrigo Borja, 42, who heads the Democratic Left Party, or Raui Clemente Huerta, a veteran politician running with support from the conservative Liberal Party, which dominated Ecuador's political life for much of the first half of the 20th century.

Two other candidates, one a conservative and the other a communist, are in the race but were not expected to get more than 5 percent of the vote.

Roldos is the son-in-law of Assad Bucaram, a populist who was banned from running for president after the military goverment passed a law saying that all eligible candidates had to have parents born in Ecuador. Bucaram's parents were born in Lebanon.

The law clearly aimed at disqualifying Bucaram, was passed because the military thinks that the popular former mayor of Guayaquil is a dangerous demagogue willing to say and do almost anything to keep his lower-class supporters happy.

While there were subtle differences between the four leading candidates, issues have never been as important as personality in Ecuadorian political history.

Ecuador has been prosperous over the past six years due to oil production, but half of the country's more than 7 million people benefit very little from the wealth, especially the Indians who live in the centralhighlands.