In an interview published here today that both defied South Africa's strict press laws and marked the first full statement by the underground African National Congress to appear here in nearly a quarter of a century, congress leader Oliver Tambo urged Pretoria to create a climate in which talks about the country's future could begin.

Insisting that the congress was neither antiwhite nor communist-led, Tambo said he was ready to declare a truce in its guerrilla struggle against the apartheid system if Pretoria would release the organization's jailed president, Nelson Mandela, and other political prisoners as an indication that it was serious about negotiations.

His statement appeared in a lengthy interview, conducted in London, with the editor of South Africa's leading liberal newspaper, The Cape Times of Cape Town, which defied longstanding stringent security laws prohibiting the publication of statements by certain individuals and organizations.

The unprecedented act of defiance by the newspaper's editor, Anthony Heard, occurred as the authorities have toughened their attitude toward the media, accusing it of fostering black rebellion. New restrictions were enacted two days ago prohibiting television, radio and photographic news coverage of the continuing racial turmoil here.

Meanwhile, prison authorities reported that Mandela, 67, who underwent surgery for an enlarged prostate gland yesterday, was making good progress in a Cape Town hospital and was expected to be out of bed by Tuesday.

In a separate development, the Rev. Allan Boesak -- a nonwhite leader whose arrest three months ago, when he tried to lead a protest march demanding Mandela's release, sparked violence in the Cape Town area -- won a court order relaxing bail conditions imposed when he later was charged with subversion.

Describing Boesak as a man of "high political morals" who was unlikely to flee the country, Magistrate W. A. de Klerk allowed the return of Boesak's passport so he could travel to the United States on Nov. 14 to receive an award.

Restrictions preventing Boesak from addressing meetings, giving press interviews or leaving the Cape Town area where he lives also were lifted, but he may not propagate divestment or boycotts, which form part of the charges against him. He is free on $8,000 bail.

Heard could be sentenced to three years' imprisonment for publishing the Tambo interview, a summary of which appeared on the front page of The Cape Times today with 3,600 words of direct quotation in question-and-answer form inside.

The law prohibits even indirect quotations by individuals or organizations declared "banned" under the security laws. Tambo and the African National Congress were banned in 1961.

No full statement by the congress has appeared in South Africa since. Occasionally the government has given permission for a brief excerpt to be published, but this usually has been when such items have seemed to support its portrayal of the organization as an antiwhite terrorist group controlled by the Soviet Union.

Heard's decision to publish the interview appears to be a calculated risk, based on an assumption that the authorities would be reluctant to prosecute at a time when there is growing public pressure for the government to begin talks with the congress.

A group of businessmen and the leader of the main opposition party in Parliament, the Progressive Federal Party, have already met with leaders of the organization at their exile headquarters in Lusaka, Zambia.

However, President Pieter W. Botha has denounced these meetings and recently had the passports seized of a group of white Afrikaner students who wanted to travel to Lusaka.

In his report today, Heard said the debate about whether there should be negotiations with the group had made it vital for South Africans to be informed about where the organization stood on critical issues.

"The Cape Times publishes the full interview as a contribution to peaceful solutions in South Africa," he wrote, adding that it regarded the issue as one of "overwhelming public importance."

Heard also noted that, whereas the congress for years had been officially portrayed in South Africa "as a communist, terrorist-type organization, almost presented to the public as demons," Tambo had come across in the interview as "an essentially moderate black leader."

Heard said Tambo urged the government to create a climate in which talks about the country's future could begin.

"We would welcome a climate of that kind," he said, adding that the release of Mandela and other political prisoners, and the withdrawal of treason charges against a number of other black leaders, were the kind of gestures that could create it.

Tambo indicated that if the government were to make such gestures it would be possible to begin talks at short notice.

But the ANC leader added that he doubted whether the Botha government was ready to make any such move yet.

Heard quoted Tambo as denying that the organization was antiwhite.

"The ANC, all of us in the ANC, have always accepted that the whites, like ourselves, belong to our country. They are compatriots, fellow citizens," Tambo said.

Asked what reassurances an ANC-led government would offer the whites, Tambo replied: "What we would hope our white compatriots will learn to understand is that we don't really see them as whites in the first instance. We see them as fellow South Africans. We see them as Africans. We were all born there in that country . . . so let's move away from these distinctions of whites and nonwhites."

Asked about Pretoria's portrayal of the congress as a surrogate of Soviet communism, Tambo admitted that the organization had some Communists among its members and that it had worked with the South African Communist Party since 1921, but he denied that it was Communist-led and claimed it was gaining more support from the West.

The group's Communist members accepted its autonomy and control over its own affairs, Tambo said.

He said an ANC-led government would seek to be nonaligned, striving to develop trade links with all countries. It would be anxious to develop trade with the United States, and would seek to reenter the British Commonwealth, from which South Africa was expelled in 1960.

It would seek to establish a mixed economic system, blending private enterprise with some nationalization to bring about a more equitable distribution of wealth in a country where there is a huge disparity between rich and poor, Tambo said.