Spencer C. Warren, a speech writer on the State Department's policy planning staff, was fired yesterday after department officials said he admitted leaking to the news media a classified cable from the U.S. ambassador in Argentina critical of House Speaker Thomas P. (Tip) O'Neill Jr. (D-Mass.) and other members of Congress.

In an unprecedented move, spokesman Charles E. Redman began his daily news briefing by announcing: "The department is dismissing a midlevel employe because he made an unauthorized disclosure of classified information to the news media."

Redman refused to name the employe. However, other department officials identified him as Warren, a political appointee with a civil service rank of GS-15 who came to State after working as a policy analyst in President Reagan's reelection campaign. Warren could not be reached for comment despite repeated calls to his office and home.

The action came two days after Secretary of State George P. Shultz angrily told the Overseas Writers Club that "we've lost all sense of discipline" about leaks and added: "It's disgusting the way the stuff leaks out. We've got to find the people who are doing it and fire them."

In another demonstration of the administration's campaign against news leaks, Michael E. Pillsbury, an assistant undersecretary of defense, was fired last month after he reportedly failed to pass a polygraph test. Pentagon sources said he had been suspected of leaking information to reporters about the shipment of Stinger antiaircraft missiles to rebels in Angola and Afghanistan.

Tensions between the administration and the news media over leaks increased last week when Central Intelligence Agency Director William J. Casey said The Washington Post, The New York Times, The Washington Times and Time and Newsweek magazines should be prosecuted under a 1950 federal law that prohibits the publication of information about communications intelligence. The statute carries a maximum penalty of 10 years in prison and a $10,000 fine.

However, in a speech yesterday to the American Jewish Congress, Casey modified his position. He said he thinks that the five news organizations violated the statute by reporting that U.S. intelligence had intercepted messages between the Libyan government and its People's Bureau in East Berlin before the April 5 bombing of a West Berlin nightclub frequented by U.S. servicemen. But Casey added that he does not favor prosecution after the fact.

State Department sources said that Warren, after being confronted with the findings of an internal investigation, had admitted that he leaked to The Washington Times and syndicated columnists Rowland Evans and Robert Novak the contents of a cable from Frank V. Ortiz Jr., the U.S. ambassador in Buenos Aires.

Ortiz charged in the cable that O'Neill and other Democratic members of a congressional delegation visiting Buenos Aires had pressured Argentine political leaders to condemn Reagan administration policies in Central America. Reports about Ortiz's cable and angry countercharges from the members of Congress were published by The Washington Post and Washington Times on April 10 and also were discussed in an Evans and Novak column a few days later.

The officials said Warren was fired yesterday morning from the speech-writing post, which carries a salary of between $52,000 and $67,000. Before leaving the department he wrote a letter of apology to Shultz, the officials added. The Justice Department has decided not to prosecute him for unlawful disclosure of classified material, they added.

The moderator of a colloquium on national security affairs in which Warren participated at Rutgers University last year said he had provided biographical material describing himself as an attorney with a degree in international affairs. The material also said he had been a "senior policy analyst" for the Reagan-Bush campaign, but campaign staff members said last night that they had only a vague recollection of Warren as a researcher.

Other officials who worked with Warren said he was one of two political appointees on the planning staff who were assigned full-time to writing speeches for senior department officials. They said that his views on major foreign policy issues were generally conservative, but they also were unable to specify a reason he might have leaked the Ortiz cable.

One source said that based on brief contacts, he regarded Warren as a conservative but "not a true movement conservative."