Sen. Edward M. Kennedy (D-Mass.) yesterday firmly ruled himself out as a candidate for president in 1984.

Kennedy, the nation's leading liberal voice and the bearer of the most famous name in contemporary American politics, said he was bowing to the wishes of his three children. He said he could not subject them to another campaign at a time he and his wife, Joan, are going through the "painful" process of a divorce.

He said he would not accept a draft from Democrats in 1984, but left open the possibility of a 1988 race when his children are older.

"I will not be a candidate," he said simply.

Symbolically, Kennedy's announcement did not take place in the cavernous Caucus Room of the 76-year-old Russell Senate Office Building, where John and Robert Kennedy -- and Ted Kennedy himself in November, 1979 -- all launched previous presidential campaigns.

Instead, Kennedy, 50, spoke in the small hearing room of the Senate Committee on Labor and Human Resources, of which he is the ranking Democrat. It was packed elbow-to-elbow with reporters, supporters and family members.

As he spoke, daughter Kara, 22, and sons Ted Jr., 21, and Patrick, 15, sat watching approvingly in the front row beside Ethel Kennedy, widow of Robert F. Kennedy, who was assassinated during his presidential campaign in 1968. His words were beamed live by all the major networks to a national television audience.

Kennedy, who is the leader in the current polls of Democrats' preference of presidential candidates, appeared calm and in complete command in what was an impressive performance. He spoke candidly of his divorce and the "cumulative pressures" on his family of running for the presidency.

"The 1980 campaign was sometimes a difficult experience, and it is very soon to ask them to go through it again," he said. "The decision that Joan and I have made about our marriage has been painful for our children as well as ourselves."

Assaults on Kennedy's personal character and morality during the 1980 presidential race and his Senate reelection campaign this fall were a key element, both politically and personally, in the decision.

Asked if this would have been an issue if he had run, he said there was "no question" that there would be "the kind of attacks on me that were made in 1980." He said he felt an "overriding obligation" to his children not to run, although the "political case" for it was "a strong one."

Kennedy's withdrawal leaves the contest for the Democratic nomination wide open, with former vice president Walter F. Mondale of Minnesota the acknowledged front-runner.

Mondale and five other Democrats have been crisscrossing the country for months preparing for the race. They are Sens. John Glenn of Ohio, Gary Hart of Colorado, Alan Cranston of California and Ernest F. Hollings of South Carolina and former Florida governor Reubin Askew.

Kennedy's withdrawal caught his opponents, Republican leaders and even his supporters by surprise. He and his aides had been actively moving toward a candidacy for months, studying polling data, contacting party leaders and recruiting staff.

"In Boston, the birthplace of the Kennedy legend, the reaction was muted as if it were just one more twist in the long and tangled tale of the Kennedy clan," reported Washington Post staff writer Bill Prochnau. "The suddenness caught most of Kennedy's presidential supporters off guard."

Until rumors began circulating Tuesday night, Democratic National Committeeman James Roosevelt Jr. of Cambridge said he had been 70 percent sure Kennedy would run. Still, few Kennedy supporters thought they were watching one of Boston's classic last hurrahs.

"I think he will run again someday," Roosevelt said. "Now it's just a little farther away than I would like."

Kennedy apparently reached his decision last weekend as the Kennedy clan gathered for the Thanksgiving holiday. On Friday, Dr. Lawrence Horowitz, the senator's top aide, went to the Kennedy family compound in Hyannis Port, Mass., to brief the family on results of polling data and prospects for 1984.

The political message, Kennedy said yesterday, was that he could win but that it would be a hard-fought campaign. His family, according to several sources, argued against running.

Kennedy has persistently been haunted by questions arising out of his automobile accident on July 19, 1969, at Chappaquiddick, Mass., in which a passenger, Mary Jo Kopechne, drowned. He and his wife, Joan, have been separated for almost two years, and are negotiating a divorce settlement.

In addition, Kennedy has been increasingly open about his dating of Lacey Neuhaus, a Texas model, for whom he recently hosted a birthday party at his McLean home.

In the end, Kennedy bowed to the wishes of his family, and news of the decision began leaking out late Tuesday.

"Over a period of weeks, I've had an opportunity to talk to the immediate members of my family and during the past several days, over Thanksgiving, we had more time to talk," he said. "I made a firm judgment based upon those assessments."

"The changed family circumstances," he said, became the "overriding consideration" since 1980, when he lost the Democratic nomination to Jimmy Carter.

The 1980 campaign ended "not that long ago," he said. "This is 1984. It's involving individuals in another campaign and there's changed family circumstances. I am involved in a divorce. It's a painful experience both for Joan and myself and for members of my family and I just felt that the cumulative effect of those kinds of pressures on the family were unacceptable at this particular time."

Kennedy telephoned his key Demcractic presidential opponents late Tuesday night about his withdrawal. Yesterday he said he had a "good deal of respect" for most of the contenders, and "I do not rule out the possibility of supporting" one of them at a later time.

He concluded with a strong hint that he might run in the future.

"Actually, I enjoyed campaigning a lot in Iowa where the presidential nominating process begins in 1980," he said. "And who knows, someday I may do it again."