In an extraordinary tape recording played before the House Assassinations Committee yesterday, Cuban President Fidel Castro denied any complicity in the assassination of President Kennedy and insisted that a warning he issued 2 1/2 months before the 1963 murder had been widely misunderstood.

His voice echoing through the Cannon Building caucus room, followed phrase for phrase by a Spanish interpreter, Castro said he had simply been trying to warn U.S. officials that he was aware of plots against his life sponsored by the Central Intelligence Agency.

"So, I said something like those plots start to set a very bad precedent, a very serious one - [and] that that could become a boomerang against the authors of those actions," Castro declared. "But I did not mean to threaten by that . . . I did not mean by that that we were going to take measures - similar measures - like a retaligtion for that."

Castro had made his seemingly ominous remarks to an Associated Press reporter he had called aside on Sept. 7, 1963, during a reception at the Brazillian embassy in Havana. "United States leaders," he warned at the time, "should think that if they are aiding terrorist plans to eliminate Cuban leaders, they themselves will not be safe."

Committee and staff members who interviewed Castro for more than four hours in Havana last April 3 neglected to ask what prompted his remarks that day or why he chose the Brazillian embassy for his forum.

It was reportedly in September 1963, however, that a longtime confidant of Castro, Rolando Cubela, met with CIA case officers in Sao Paulo, Brazil, and said he would be willing to attempt Castro's assassination if the U.S. government would support him.

According to Edward J. Epstein's recent book, "Legend: The Secret World of Lee Harvey Oswald," Cubela's startling offer was communicated to CIA headquarters on Saturday, Sept. 7, 1963. Castro's remarks at the embassy in Havana the same day reportedly raised suspicious among some CIA officials that Cubela, code-named Amlash, might be a double agent.

The interview with Castro was played as the House committee reached what appears to be a dead end in its efforts to resolve the question of possible foreign entanglements in the president's assassination in Dalas on Nov. 22, 1963.

The Soviet Union has refused the committee's request for various documents, including the KGB's voluminous surveillance files on Oswald during his 2 1/2-year stay there. Yesterday, chief committee counsel G. Robert Blakey reported that the panel has been "largely frustrated in its attempts to investigate the nature of Lee Harvey Oswald's activities and possible associations in Mexico City" in late September and early October of 1963.

Among the loose strings:

A man employed at the Cuban embassy when Oswald went there on Sept. 27, 1962, abruptly left Mexico City the day of a prearranged interview and finally refused to speak with House investigatiors when they reached him, by happence, by telephone. The committee refused to make public the man's name or even his nationality, apparently because of a declassification problem. Blakey refused to comment when asked if the individual might have been a CIA informant.

Long-ignored reports that Oswald and two other Americans attended a party in Mexico City in early October 1963 where Cuban Consul Eusebio Azcue was also an invited guest have foundered on the committee's inability to secure the testimony of Mexican author Elena Garro de Paz. She first told the story to the late American Foreign Service officer Charles Thomas in October 1964. Now retired, Azue, who testified before the committee Monday, hotly denied ever attending such a party and called the story "incredible." Blakey described it as "interesting" but said that at attempts to get Garro, now in some other country, to testify "have been unsuccessful."

The committee has evidently been unable to get the CIA to concede publicly that it maintained photographic surveillance of individuals visiting the Cuban consulate in September 1963 - despite the fact that the Cuban government has provided the committee with photographs of the alleged CIA photographic surveillance site. The CIA failed to take Oswald's picture, although he visited the consulate on three occasions.

Reports that Castro had heard that Oswald might kill Kennedy, ostensibly because of remarks Oswald made at the consulate, remain unresolved, denounced on the one hand by the Cuban government as a "disinformation effort of the Central Intelligence Agency" and supported on the other by sources that U.S. intelligence regards as "highly confidential but reliable."

The committee's questioning of Castro on this and other points was gentle, circumspect and far from thorough despite the length of the interview. The Cuban president denounced talk that he had advance warning of Oswald's intentions as "absurd." The committee put the question to him only indirectly, by showing him a melodramatic account of the allegation in the National Enquirer.

"I would never have given a journalist an interview in a pizzeria," Castro declared after reading the Enquirer article. "It has been invented from beginning to end."

On the larger question of whether he or any other Cuban official might have had some connection with the assassination, Castro denied it vigorously.

"Who here could have operated and planned something so delicate as the death of the United States president?" He asked rhetorically. "That was insane. From the ideological point of view, it was insane. And from the political point of view, it was a tremendous insanity . . . The leaders of the Cuban revolution have never made that kind of insanity, and that I may assure you."

Castro said Cubela was tried and sentenced some years ago "for the plots against our lives," but the declared that he had not known of Cubela's CIA backing until the Senate's CIA investigations several years ago.

Now in a Cuban prison. Cubela, who was meeting with the CIA in Paris the day Kennedy was killed, told the committee the same story.

"He said that during [his] prosecution [for plotting against Castro], he did not inform the Cuban government did not learn, that his plot had the support of CIA personnel," Blakey related.

Sprinkling the interview with his spontaneous assessments of other U.S. president, Castro said he does not think Jimmy Carter would be capable of ordering all the subversion and sabotage his regime has sustained in the past from CIA-sponsored campaigns. But he said, "I would not have trusted [Lyndon] Johnson" and he described Richard M. Nixon as "a man without scruples." He said Nixon wanted to send the Marines to invade Cuba.

"Had Nixon been president during the [1961] Bay of Pigs invasion, a landing by the military Army of the United States would have taken place." Castro declared. "We are absolutely convinced of that."