A leading moderate in the French Communist Party was ousted today from the decision-making Politburo in what was seen as a political victory for hard-liners opposed to any loosening in the party's strong ties with Moscow.

At its closing session in this working-class suburb of Paris, the party's 25th congress unanimously reelected Georges Marchais as secretary general despite growing complaints about his leadership among rank-and-file Communists and a dramatic slump in the Communist vote in recent elections.

Party spokesman Pierre Juquin, who has led the drive for greater internal democracy in the party during the past six months, lost his place on the party's 22-member Politburo. Two other dissidents were dropped from the less powerful 140-member Central Committee, but three reformers, including Juquin, were reelected to this body.

The mini-purge suggested that Marchais has succeeded in reasserting his authority over the party, at least for the time being. The 64-year-old secretary general said that the party had shown itself "strong and mature enough" to tolerate free internal debate.

Marchais, who has led the party since 1972, defended the controversial Leninist principle of "democratic centralism," which obliges dissidents to support decisions made by the majority. He was applauded loudly when he said that there was no question of the French Communist Party transforming itself into a social democratic party.

The remark was seen as a rebuke to would-be reformers such as Juquin who have urged that the party follow the example set by the Communist Party in Italy. While popular support for the French party has dropped to a 50-year low, the Italian Communist Party has consolidated its influence and last year received more votes than the dominant Christian Democrats.

Many commentators here believe that the French Communist Party, which pulled out of the Socialist-led coalition government last July, has condemned itself to a "political ghetto." Faced with declining membership and declining morale, Communist leaders have sought refuge in Marxist dogma and party discipline rather than risk change.

The congress demonstrated that, despite an unprecedented degree of discontent among party members, the dissidents are neither organized nor numerous enough to force a showdown with the leadership. Of the 1,717 delegates to the congress, only 65 abstained on the final resolution endorsing the policies of the leadership.

The meeting ended with the traditional scenes of carefully stage-managed jubilation as delegates stood on their chairs to congratulate a beaming Marchais on his reelection. Confetti made out of back copies of L'Humanite, the party newspaper, and congress resolutions was thrown into the air.

Political analysts believe, however, that the phenomenon of dissent could have a significant impact in the long term if the Communist vote continues to drop below its present level of 11 percent.

In his speech to the congress Friday, Juquin attributed the drop in support for the Communist Party to its refusal to listen to criticism. He said that the party was in danger of losing "a race with history" by failing to introduce internal reforms.

The apparent victory of the Communist Party hard-liners represents a further problem for Socialist president Francois Mitterrand, who must now deal with both a right-wing and a left-wing opposition.