President Valery Giscard d'Estaing and Socialist Party leader Francois Mitterrand emerged from the first round of voting today in the two-stage French presidential election as the contenders for the runoff vote in two weeks.

The runoff, a replay of the Giscard-Mitterrand race seven years ago, is likely to be at least as close as in 1974, when the present incumbent won by about 450,000 votes.

With 96 percent of the 30 million votes case today counted, Giscard had 7.9 million votes, or 27.9 percent, and Mitterrand had 7.4 million, or 26.1 percent, a difference of less than 2 percent. Had any candidate won an absolute majority today, the runoff would have been unnecessary.

Giscard went on television to challenge Mitterrand to two televised debate -- one on economic and social policies and the other on foreign and domestic policies. A Mitterrand spokesman said the Socialist would only accept a single televised debate on all subjects.

The incumbent president stressed in a statement tonight that "Mitterrand needs communist votes" to win. Interior Ministeer Christian Bonnet said the two candidates remaining in the race "propose two profoundly different types of society" for the choice May 10.

Mitterrand called Giscard "the president of unemployment, social injustice and inequalities."

The French Communist Party was today's biggest loser, dropping to 15.4 percent of the vote, its lowest showing in 45 years. Communist leader Georges Marchais said that at least 1.5 million normally communist voters had cast ballots for Mitterrand rather than for him because they were mistakenly responding to the Socialist appeal not to divide the vote of the left. The last time the communists ran their own candidate, Jacques Duclos in 1969, he got 21.5 percent.

Gaullist candidate Jacques Chirac, in an attempt to beat out Mitterrand, apparently helped him. Chirac's spirited challenge seemed to prompt significant numbers of communists to vote for Mitterrand on the first round -- and thus to avert the possibility that no leftist candidate would be present in the runoff.

Marchais' poor showing reinforced the widespread impression that his days as party leady may be numbered. But it also raised the question of whether a weakened Communist Party will react by continuing its previous efforts to thwart Mitterrand, or follow the lead of a large portion of its own electorate that obviously rejects the party's hard-line resistance to the rise of the Socialist Party as the dominant force in the French left.

Mitterrand's vote was the largest the French Socialist Party has won in its long history.His victory May 10 would represent a major reversal in the Western trend toward conservative governments set by the coming to power of Margaret Thatcher in Britain and Ronald Reagan in the United States.

A Mitterrand presidency could tip the fine balance against the left inside Western Europe. In West Germany, Mitterrand has close relations with socialist former chancellor Willy Brandt, who is allied with the ruling party's neutralist-inclined elements, and cool ones with the present socialist leader, Chancellor Helmut Schmidt. Schmidt is Giscard's closest political partner in the European Community.

Paradoxically, however, French foreign policy could emerge from a Mitterrand victory more in tune with the anti-Soviet mood of the Reagan administration. Mitterrand, despite his dependence on communist voters for his election, has contributed to the general criticism during this campaign of Giscard's alleged softness on Moscow.

Giscard's total was running about 4.5 percentage points lower than he got in the first-round voting seven years ago. Mitterrand did significantly better than most opinion polls had predicted.

Marchais produced his party's lowest percentage showing since the Popular Front election of 1936. Since World War II, the communists have consistently polled more than 20 percent of the vote. The Marchais campaign, whose response to heavy unemployment included appeals to working-class racism against foreign immigrant laborers from North Africa, clearly offended the party's antiracist and intellectual elements.

Gaullist candidate Chirac won 17.9 percent of the vote, generally considered a good showing in light of the low level from which he started in the polls.

Two minor Gaullist candidates, former premier Michel Debre and former Chirac adviser Marie-France Garaud, split between them about 3 percent, meaning that the total Gaullist vote was almost 21 percent. This was a big jump compared to the 15 percent for Gaullist presidential candidate Jacques Chaban-Delmas in 1974, and to the 16 percent showing of the Gaullist list in the European Parliament elections in 1979.

Chirac spokesman hinted that their leader would wind up supporting Giscard in the runoff, but they also indicated that the Gaullist would do so just as reluctantly as the Communist Party would back Mitterrand.

Gaullist Party Secretary General Bernard Pons said Giscard needed "to learn the lesson" of the first-round voting by adopting new economic policies and paying heed to Gaullist criticisms. The 5 million people who voted for Chirac did so to express their discontent and disillusionment with Giscard, Pons said. When Giscard appeared on television tonight, he was booed by party workers at Gaullist campaign headquarters.

Environmentalist candidate Brice Lalonde, with nearly 4 percent, led the six minor candidates. His voters are expected to split in about equal numbers between Giscard and Mitterrand. Lalonde said he would endorse neither.

Three minor leftist candidates shared about 5.5 percent of the vote. All three of them called on their voters tonight to elect Mitterrand in the runoff. Most communist voters are also expected to shift to the Socialist leader regardless of their party's hesitations.

Government statistics stressed that the combined vote of Giscard and the three Gaullists was 49 percent, with 47 percent for the five leftist candidates. But Giscard cannot count on all of the Gaullist voters. Some are bound to vote for Mitterrand and others to stay home on May 10. The question is whether that shift could be enough to overcome the communist voters who deny Mitterrand their ballots.

In 1974, the combined Giscard and Gaullist vote on the first round was 47.7 percent. The combined leftist vote was 45.9 percent, of which 43.2 percent went to Mitterrand alone. But the Communist and Radical parties, which both ran candidates this time, were then supporting the Socialist on the first round.

Only about 80 percent of the electorate, which now numbers 37 million, turned out today, compared with about 85 percent in 1974. Part of the reason may be the far larger number of young people now eligible to vote, since Giscard had the voting age lowered from 21 to 18. Another factor may be dissatisfaction with the choices offered. An unusually large portion of the voters were telling pollsters late in the campaign that they were still undecided.