President Reagan will address the Soviet people and Soviet leader Mikhail Gorbachev will address Americans in an exchange of televised New Year's greetings, White House spokesman Larry Speakes announced today.

The televised messages, which will run three to five minutes, are the fruition of several months of diplomatic efforts by the administration to get Kremlin approval for a Reagan address to the Soviet people.

"It is our understanding that the Soviets will air the president's message in its entirety," Speakes said. In Moscow, foreign ministry spokesman Vladimir Lomeiko announced the joint agreement and said the Reagan message will appear at 9 p.m. there, a slot that corresponds to U.S. prime time because it is the time of the main news program.

It will be the first time a U.S. president has spoken directly to the Soviet people on television since Richard M. Nixon made an appeal for world peace and improved U.S.-Soviet relations in Moscow on May 28, 1972, the last day of a week-long official visit.

Using Nixon's speech as the model, Charles Z. Wick, director of the U.S. Information Agency, a year ago proposed an exchange of televised speeches during the November summit in Geneva. But negotiations were at first unsuccessful, and Reagan settled for a radio speech over the Voice of America on Nov. 9 that was partially jammed in the Soviet Union and Eastern Europe.

Officials said negotiations continued through diplomatic channels after the summit. "We got a positive response from the Soviets in the last three or four days and we were working through yesterday to work out the details," Speakes said.

The speeches will be taped and exchanged through embassies in Washington and Moscow. They will be available for U.S. television and radio broadcast at 1 p.m. EST New Year's Day, although some networks may delay broadcast slightly.

ABC, NBC and Cable News Network spokesmen said they would broadcast the Gorbachev message, while CBS officials said they had not yet decided how to handle the talk. Speakes said the administration had not asked the networks to carry Gorbachev's speech because "there was no way we could ask them to do so . . . under our system."

Reagan will tape his message to the Soviets from the Century-Plaza Hotel here, using facilities of one of the networks, shortly after he delivers his regular Saturday radio broadcast. The radio speech is expected to be a condemnation of Soviet occupation of Afghanistan, similar to the statement Reagan issued today on the sixth anniversary of the Soviet invasion.

Officials would not discuss the contents of Reagan's message on New Year's Day, other than to say it was designed to further U.S.-Soviet understanding.

"We feel that both sides will be extending greetings in a spirit of good relations," Speakes said.

This would seem to rule out the harsh condemnation of Soviet policies in Afghanistan and other world trouble spots that Reagan made in an interview with Soviet journalists and in a speech to the United Nations in October. Portions of Reagan's comments on Afghanistan and human rights were edited out of the interview as it appeared in Soviet newspapers.

White House concern about the New Year's Day message appeared to be directed more at possible leaks by U.S. television, which will have possession of a copy of the Reagan tape, than at Soviet censorship.

"We're counting on the integrity of the networks to abide by their embargo," said Mark Weinberg, deputy White House press secretary, on the chartered plane carrying reporters to California.

As he has for many years, Reagan will spend New Year's Day in Palm Springs, where he probably will play his "annual round of golf," Speakes said. The president and Nancy Reagan will attend a New Year's Eve party at the estate of wealthy publishing magnate Walter Annenberg.

Reagan will stop in Mexicali on his way home to Washington Jan. 3 for a meeting with Mexican President Miguel de la Madrid. The meeting was requested by the Mexican president and U.S. officials said there is no agenda for the discussions.

Except for the Mexicali stop, the week is scheduled as one of almost complete rest for Reagan, who exchanged the subfreezing temperatures of Washington for pleasant Southern California weather with temperatures in the low seventies. There are no official activities on the schedule and meetings will be kept to a minimum.

Speakes discounted a published report that Nancy Reagan was seeking a cutback in the president's 1986 schedule. He said the schedule hadn't been developed yet but that Reagan would "travel when necessary" in the midterm election year, "concentrating on races that need presidential help."