Justice William J. Brennan Jr.'s resignation last night, giving President Bush his first opportunity to name a justice to the Supreme Court, will almost certainly move the court further to the right in its decisions on the most important issues facing the country -- including abortion, racial discrimination, separation of church and state and freedom of speech.

President Reagan's three appointees, and his naming of Justice William H. Rehnquist to be chief justice, had already given the court a 5 to 4 conservative majority that led to many decisions trimming a number of liberal precedents.

The vote of an additional conservative, even a moderate, would transform that slim, often tentative majority into an activ-ist conservative court, liberal and conservative analysts said last night, because it would eliminate the pivotal role often played by the fifth, or "swing," justice.

The "swing" vote in recent terms has come from Justice Sandra Day O'Connor or, in some cases, Justice Byron R. White. The swing vote in a 5 to 4 decision controls how liberal or conservative a ruling will be, because the majority must temper or moderate its opinion to satisfy the views of the wavering justice.

That is why the court under Rehnquist has not been as markedly conservative as some conservatives had hoped and has often produced narrow opinions in the most controversial cases.

In addition, justices traditionally have been averse to overruling precedent on a bare five-vote majority, though they will do so on occasion. But a sixth vote will make the conservative majority much freer to flatly overrule earlier decisions.

O'Connor, for example, has been the roadblock to the conservative majority's willingness to effectively overrule Roe v. Wade, the 1973 ruling declaring a constitutional right to abortion. In addition, her votes have been pivotal on some affirmative action cases and in disputes involving church-state relations. White's votes have been critical in cases involving federal judicial power and affirmative action.

Conservative court analyst Bruce Fein said last night that the Brennan resignation would transform the high court into "a conservative juggernaut, the equivalent of the New Deal court of Franklin D. Roosevelt," especially on the "social, civil rights issues."

"Part of the reason that the court, even with a 5 to 4 conservative majority, has not been down-the-line conservative," Fein said, is because of its narrow majority. "But the addition of one more vote, that would do it," he said.

Duke University Law School professor Walter Dellinger, a liberal, agreed. "It's hard to imagine any replacement nominated at this time who would not produce a remarkable shift to the right of the court," he said. "In most areas, there will be nothing approaching a swing justice any more. This could be a tragedy for the court and the country."

Without Brennan, Dellinger said, "many of the major decisions of the court this term would have come out differently," including the flag burning case and the affirmative action case involving two Federal Communications Commission programs giving minorities preferences in granting of licenses.

The court's shift will be pronounced whether Bush appoints a moderate conservative or one in the mold of most of the conservative Reagan appointees, most analysts have said, because it will substantially increase the ability of Rehnquist, a conservative elevated to chief justice by Reagan, to put together five solid conservative votes.

With so many explosive social issues, especially abortion, in the balance, Bush's nomination may also trigger a bitter Senate confirmation battle, plunging the court back into partisan politics only three years after the fight over Judge Robert H. Bork's nomination.

"The key to avoiding that," Dellinger said, "would be whether there is a genuine process of advice and consent of the Senate. It would be appropriate for a genuine process of consultation between the president and the Senate leadership in order to avoid the kind of divisive conduct we saw with the Bork nomination."

Sen. Patrick J. Leahy (D-Vt.), a member of the Senate Judiciary Committee, said "the pressure on the president within his own party will be to greatly alter" the balance on the court "because those who want a more conservative court will now see a possibility of irrevocably establishing that for the rest of the century and beyond."

Liberals were dismayed by the announcement. Norman Dorsen, national president of the American Civil Liberties Union, called the resignation "an incalculable loss to the law and lovers of liberty everywhere. Justice Brennan has been a courageous, brilliant and, above all, humane justice."

Sen. Edward M. Kennedy (D-Mass.) said Brennan had "earned an extraordinary place in American history and American constitutional law. He ranks with Marshall, Holmes and Brandeis as the greatest justices the country as ever had."

Eleanor Smeal, president of the Feminist Majority, said, "Brennan's resignation is a call to arms for American women. Neither the president nor the U.S. Senate will be able to duck the abortion issue this time. A Trojan horse nominee who has no public position on abortion will have no chance for confirmation."

Sen. Strom Thurmond (R-S.C.), a Judiciary Committee member, said, "Justice Brennan has a keen intellect and is an able writer. He is considered a very liberal judge on the court, and his philosophy is not in accord with mine. However, I respect his views and I hope that his health will improve and that he will enjoy his retirement."

Brennan's longtime colleague and fellow liberal, Justice Thurgood Marshall, told the Associated Press that Brennan has been a "voice of caution and compassion in urging that this court not retreat from its constitutional mission to protect individuals' rights of freedom and expression, guarantee that minorities be free from discrimination and to assure the rights of those accused of crimes."

Staff writer David S. Broder contributed to this report.