Javier Perez de Cuellar, a 61-year-old Peruvian diplomat and former U.N. under secretary, was chosen by the Security Council today to serve a five-year term as the next secretary general.

Perez's nomination now goes to the General Assembly, where it is scheduled to come to a vote Monday. The nomination is expected to be overwhelmingly approved by the assembly, which is made up of a majority of Third World countries eager to endorse a candidate from within their ranks. If approved, Perez would be the first secretary general from Latin America.

The Security Council vote today came after a six-week deadlock in the race between the current secretary general, Kurt Waldheim, and Tanzanian Foreign Minister Salim A. Salim, the candidate of the African group and the nonaligned movement. Through 16 ballots the Chinese, who favored a Third World candidate, vetoed Waldheim and the United States vetoed Salim. Waldheim withdrew his candidacy last week and Salim withdrew from consideration Tuesday, although both men said they would be available for a draft.

After Salim's withdrawal, Perez and eight other candidates stepped in. But the choices had stirred little debate, and none of the 15 council members had indicated a preference before Perez won on the first official ballot today.

Perez avoided much of the bruising behind-the-scenes politics of the stiff campaign by staying in Lima throughout the race, rather than lobbying in U.N. corridors or granting press interviews, as others did. He thus comes to the $158,000-a-year job on Jan. 1 with the appearance of a clean slate -- an equal debt to all U.N. power blocs.

In Lima, Perez greeted news of his selection "with satisfaction," The Associated Press reported.

He said he would not be able to avoid giving preference to Third World problems, "not because the Third World is in a majority in the U.N. General Assembly but because the prosperity of the Third World will determine the prosperity of the First and Second Worlds," Reuter reported. "My aim is to contribute to the peaceful solution of world problems."

He blamed most of the world's tension on the East-West ideological conflict, according to AP. "There are many critical points where peace is threatened , but the prime problem is the East-West relationship," he said in an interview.

Perez had the most extensive and varied U.N. experience of all the candidates except for Waldheim, who is finishing his second term on Dec. 31.

After serving as Peru's first ambassador to Moscow from 1969 to 1971, he was Lima's chief U.N. representative for the next four years, serving two years on the Security Council. Then he joined the U.N. staff to serve as its representative on Cyprus for two years and later as one of the under secretaries responsible for U.N. peace forces until this May.

While in this post, he also was chairman of the U.N. appointment and promotions board, where he became familiar with the deep-seated personnel and morale problems the organization faces.

He is still the U.N. envoy responsible for dealing with the Afghanistan dispute, and in this job, diplomats say, his caution helped reassure Moscow that he could be trusted not to act against their interests.

The Soviets were reported to be a possible stumbling block to his candidacy, since they traditionally have vetoed all Latin Americans in the past.

In a straw ballot among council members at a closed meeting this morning, Prince Sadruddin Aga Khan, the former U.N. High Commissioner for Refugees, reportedly received the most votes, but the Soviets indicated their opposition to him.

Perez reportedly had eight votes in the straw poll, but he emerged as the favorite because he was the only one with no vetoes. Council members are allowed to vote for more than one candidate, and the five permanent members retain veto power.

In the formal ballot this afternoon, council sources said, Perez won 10 votes, one more than the required minimum, and received no vetoes. Sadruddin tallied nine votes and again the Soviet veto, they said. None of the other seven candidates won a majority.

Observers here were divided on their assessment of Perez's capabilities. Some officials who have worked with Perez view him as a cautious individual who is sensitive to pressures from individual governments on the political or adminstrative fronts. Others questioned whether he will be innovative in helping to solve many of the tangled issues before the United Nations.

American Ambassador Jeane J. Kirkpatrick, however, believes "he's going to do well -- or we wouldn't have supported him."

She praised Perez for "imaginative problem solving" on such assignments as observing the Zimbabwean elections for the the United Nations. His prime asset, she said, is that "he has a great deal of relevant experience."

The United States, Kirkpatrick added, "decided on the basis of the man, not his origin, but we are delighted to have a secretary general from a neighboring state with which we feel close and friendly ties."

Brian Urquhart, the under secretary who worked with Perez on the U.N. peace forces and is expected to become his prime political adviser, praised his former colleague for his "great integrity." With his knowledge of the United Nations, Urquhart said, "he will develop on the job."

One former colleague praised Perez for his creativity and his ability to use staff well. "He never did a dishonest or cheap or underhanded thing, and for this we all have affection for him," the staffer said.

"There is no lack of ideas and initiatives here. There are people on his staff who will see to that. But this job is sui generis; there is no way to tell until he moves into it whether he will grasp the opportunities or shy away from them. With me, in the past, he has always grabbed the chance and run with it."

Waldheim congratulated Perez by phone and issued a statement expressing the certainty "that he will make an excellent contribution to the work of the U.N."

Later last night Waldheim told reporters he would eventually return home to Austria and "do some writing."

The other candidates in today's voting were Rafael Salas of the Philippines, head of the U.N. Population Fund; Argentine diplomat Carlos Ortiz de Rosas; Foreign Minister Jorge Illueca of Panama; U.N. Ambassador Radha Ramphul of Mauritius; Commonwealth Secretary General Shridath Ramphal of Guyana; former Ecuadorean president Carlos Julio Arosemena Monroy, and Santiago Quijano Caballero of Colombia, a U.N. official in Geneva.