President Reagan has left in place a sensitive CIA covert operation designed to increase U.S. influence in Iran despite his decision not to sell more arms to the Iranians.

Several sources in the administration and on Capitol Hill said last week that this ongoing operation is diplomatically risky and is likely to aggravate turf struggles within the administration.

But the president and some of his senior White House staff see the continuing covert Iran operation as a bold initiative that has yielded positive results -- the release of three American hostages -- and has a chance to achieve other foreign policy aims, according to official sources.

The covert action authorized by Reagan's Jan. 17 secret intelligence "finding" allows the Central Intelligence Agency to interfere in the affairs of a foreign government. The operation is an extension of one initiated by Israel, and according to senior Reagan administration officials, it is designed to gather intelligence and shape the behavior of the regime of Ayatollah Ruhollah Khomeini and that of his successor.

Administration officials have said that the covert operation is not a paramilitary support plan and is not intended to seek the overthrow of Khomeini. The administration wants to keep the program as secret as possible -- one reason the White House has left in force the covert finding that allows it to keep more details of the policy out of public and congressional view.

"The agency has got its hooks into some people in Iran and is embarked on a pipe dream that they can kick open the door to Tehran," said one middle-level administration source knowledgeable about Iran and opposed to the operation.

A source said Khomeini has not been able to determine the identities of the U.S. contacts in his government or has for some reason sanctioned their dealing with the United States. Two U.S. sources raised the possibility that the Iranians have engaged in an elaborate "sting" operation to obtain arms and embarrass the United States.

The president said Wednesday night in his televised news conference, "We are hopeful that we're going to be able to continue our meetings with these people, these individuals."

Secretary of State George P. Shultz and other senior State Department officials have opposed the project not only because of the arms sales but because the covert operation gives the CIA and the National Security Council in the White House primary roles in attempting to manage and develop new U.S. foreign policies toward Iran, the sources said.

Informed sources described the CIA's director, William J. Casey, as a strong supporter of the covert plan.

Covert operations, even those involving paramilitary action such as CIA support to the contras opposing the Sandinista government in Nicaragua, are traditionally managed by interagency groups chaired by a senior State Department official. But the Iran project was run by the White House and the CIA.

One well-placed source said part of the controversy over the secret Iran policy is a turf battle, but another source familiar with Shultz's thinking said the secretary of state simply wants to regain authority over this interagency machinery and what he thinks should be largely a diplomatic initiative to Iran, not an intelligence operation.

Intelligence agencies have played roles in the Iran project since its inception, although the CIA's active involvement began only last January -- after the operation became too complicated to be run entirely out of the White House, according to a knowledgeable source.

The first contact setting the project in motion was in late July 1985, between Robert C. McFarlane, then the president's national security adviser, and David Kimche, then director general of the Israeli Foreign Ministry, according to U.S. sources.

Kimche, a 30-year veteran of Israel's Mossad intelligence service and a former Mossad deputy director, has been a key figure in developing Israel's antiterrorism policy over the years, according to informed U.S. and Israeli sources.

The Mossad's technique against Palestinian terrorists has always been to penetrate the groups with agents. And sources said that one of Kimche's favorite expressions was, "In order to catch a fish, you have to think like a fish."

But after the Iranian revolution, a new wave of terrorist attacks and bombings by Shiite fundamentalists loyal to and supported by the Khomeini government presented both Israel and the U.S. intelligence agencies with a new problem of gathering intelligence. In the words of one source, "We had to learn to think like different fish."

The 1983 terrorist attacks against U.S. installations in Beirut, including the devastating bombing of the Marine barracks that killed 241 U.S. servicemen, highlighted the problem.

Both Israeli and U.S. intelligence agencies developed information that the Iranian government was a chief supporter of the terrorist groups responsible. For example, Iranian diplomatic communications were used to order terrorists in Lebanon to conduct some operations, according to informed sources.

U.S. and Israeli sources said that by 1985 the Mossad had developed a high-level source in the Khomeini government through channels that had been opened with secret Israeli arms shipments to Iran.

In the July 1985 meeting with McFarlane, Kimche effectively passed along an Israeli intelligence asset to the United States, according to one source.

It was "natural" that this contact eventually be taken up by the CIA, the source said, especially when Shultz and Defense Secretary Caspar W. Weinberger voiced opposition to a new opening to Iran that would include arms shipments.

The New York Times yesterday quoted an unidentified senior Israeli official who described the intelligence asset Israel had cultivated in Tehran in these terms: "We are talking about a source among the most senior ayatollahs. It would have been criminal for us not to follow up . . . . We were getting some terrific intelligence through this channel . . . . We were at the heart of the government. There was no Western government that had access to the kind of information we had.

"Through these contacts, we learned a great deal about what was going on in the ruling circles. It became clear to us that there were different groups, some less zealous than others."

Covert CIA relationships with senior officials in foreign governments have been among the most sensitive and controversial in the U.S. government. Diplomats often oppose them. For example, for 20 years the CIA had a secret relationship with King Hussein of Jordan and paid him millions of dollars. Until the operation was disclosed publicly in 1977 and discontinued by President Jimmy Carter, the CIA station chief in Amman had more influence and access to the Jordanian head of state than did the U.S. ambassador.

The Jan. 17 order was issued under the 1980 Intelligence Oversight Act, which requires the president to "find" that a new covert action is "important to the national security of the United States." Thus this formal written presidential approval for covert action is called a "finding."

A source said that CIA Director Casey and his general counsel were involved in drafting the finding. Poindexter has said publicly that the only copy of the finding was kept in his White House safe.

According to sources, Poindexter thinks that a new generation of Iranian officials, so-called "moderates," have less of a phobia about the West than some of the elders who staged the Iranian revolution, and believe that the greatest threat to the Iranian revolution is posed not by the United States but by the Soviet Union, which shares a 1,100-mile border with Iran.

One official said, "All you have to do is point out to them what's happened to Afghanistan, which is also on the Soviet border. These moderates in Iran know . . . that the Soviets are a threat." The Soviets invaded Afghanistan in 1979 and have kept about 100,000 regular troops there in a continuing war against the Afghan resistance.

Sources said that one of the goals the president listed in the secret intelligence order he signed Jan. 17 was to prevent the Soviets from obtaining a foothold or increased influence in Iran.

Sources this week said that controversial arms shipments to Iran not only helped win the release of American hostages but were a means of rewarding and giving leverage to key Iranians who are the high-level U.S. connections into the Iranian government.

The sources said these U.S. connections are the "individuals" and "people" Reagan mentioned but did not identify in his news conference Wednesday. The president said the arms sales were to give "prestige and muscle" to "the people that we were doing business with."

Normally, CIA sources or contacts in foreign governments are paid with money, intelligence assistance or physical protection, but the Iranian contacts wanted arms, the sources said.

"In the Middle East, whether we like it or not, arms are a currency, in the broad sense of the word," Poindexter said in an interview last week with USA Today.

A senior official said: "We had to establish our bona fides. And we frankly didn't trust them, didn't trust Iran, didn't trust the channels we were dealing with. They didn't trust us. There was no mutual trust. We're the Great Satan. So how do you establish your bona fides? Do you try powdered milk? Do you try bandages? That's something they can get at the local drug store. You have to try arms."

Administration officials argue that Reagan did not see the Iran policy as a modification of his strong stand against terrorism and countries that support it.

Said one well-placed official, "Reagan believes in his heart that we didn't deal with terrorists in Iran but dealt with those channels that are moderate, and moderate is a term that is relevant to Iran" -- a contention that some experts on Iran have disputed.

Administration officials listed these positive developments as fruits of the Iran initiative:

"The Iranian government has not sponsored a terrorist act against Americans or U.S. interests since secret Reagan administration contacts began in 1985.

The three Americans kidnaped in Beirut this September and October had all converted to Islam and were either longtime residents of Beirut or had married Arab women. "It's not as if they're picking off American tourists or American government people like they have in the past," said one official, who claimed that the kidnaping of Joseph James Cicippio, Frank Reed and Edward Austin Tracy were not necessarily anti-American acts.

"Iran has issued government statements against terrorism.

"Three American hostages in Beirut were released -- the Rev. Benjamin Weir on Sept. 14, 1985, the Rev. Lawrence M. Jenco on July 26 and David P. Jacobsen on Nov. 2.

"Iran assisted in obtaining the release of several of the hostages of TWA flight 847 in June 1985; Tehran also refused to provide landing rights for the Pan Am jet hijacked in Karachi, Pakistan, this September.

Staff researcher Barbara Feinman contributed to this report.