President Reagan may try to close the Beirut airport and blockade Lebanon with U.S. naval forces if diplomatic efforts to free the 40 American hostages from TWA Flight 847 are not successful within the next few days, White House spokesman Larry Speakes said yesterday.

Speakes said these were two of several economic and military options discussed with the president yesterday afternoon during an 85-minute meeting of the National Security Council. An administration official said they were intended as "a warning" to the captors of the hostages that Reagan's "patience was not limitless."

The "warning" could be military, but officials said the principal discussion at the NSC meeting was of economic sanctions -- a government-sponsored airline boycott to force the closing of the Beirut airport, and concerted efforts by the United States and other countries to isolate Lebanon economically.

Public discussion of these new options signaled another abrupt change of tactics for the administration, which has been pursuing a variety of diplomatic approaches designed to free the hostages.

Senior U.S. government specialists said a sense of urgency is growing within the administration and cited increasing concern that securing release of all of the hostages will become more difficult the longer the crisis continues.

In this view, Nabih Berri, leader of the Shiite Amal movement that claims custody of most of the hostages, can still deal with the hijackers to free all of the captives.

As time passes, however, these specialists said, they fear that the hijackers' terms could become more extreme, for example, demanding that Kuwait also release terrorists held in its jails. Kuwait will not do so, they said.

As recently as Monday, the White House played down talk of any military option and emphasized diplomatic efforts to free the hostages. Last week, at his news conference, Reagan said he would "wait it out as long as those people are there and threatened and alive, and we have a possibility of bringing them home -- I'm going to say a probability of bringing them home."

But "nothing has happened" so far to free the hostages and the president "wants action," Speakes said yesterday.

Officials said the most promising diplomatic effort appeared to be influencing Syria to bring pressure on Berri. But Speakes said this and other efforts "have not borne any direct results."

There were signs of frustration, impatience and some confusion yesterday at the White House on the 12th day of the hijacking. Officials said that Reagan asked for a full review of diplomatic efforts, and of alternative options if diplomacy failed.

But while Speakes spoke of many possible options, a source familiar with the discussions at the NSC meeting said the focus was on closing down the Beirut airport and the possible blockade of Lebanon. Some government officials and numerous nongovernment experts said both options offered little chance of dramatically altering the situation in Beirut.

Speakes did not rule out military means of shutting down the airport, including warning flights by U.S. fighter aircraft and bombing of the runways. But officials said the government has devoted more attention to the possibility of concerted economic penalties.

The proposed airport boycott would involve the refusal by the United States and its allies to allow airlines operating within their borders to fly to Beirut. To make the boycott tighter, Mideast Airlines or any other carrier serving Beirut would not be allowed to feed passengers into connecting flights in the countries participating in the airport-shutdown effort.

The proposed economic boycott included several options, officials said, including a blockade of Lebanese ports and the agreement of cooperating countries to refuse to ship key items to Lebanon and to attach bank accounts of Shiite groups and leaders. The overall aim would be to make life uncomfortable for large segments of the Lebanese population on the assumption that in seeking relief they would put pressure on the Shiites to free the American hostages.

When a reporter suggested to an official that this was improbable, he replied: "I didn't say it will work. I said that's the thinking and rationale that produced the idea."

The administration's attempt to up the ante in dealing with the hostage situation was unveiled at the White House at a morning briefing by Speakes, who said Reagan had "set into motion the development by his national security staff of a series of measures that could increase the pressure on those who are holding our citizens, and on those who support the terrorists." Speakes said these measures included the airport closing and stopping some "goods and services" to Lebanon.

But when asked whether a naval embargo would be needed, he cautioned reporters not "to immediately jump to military conclusions."

Throughout the day, however, officials gave different signals about what the White House was trying to accomplish amid signs of tension and growing division within the administration on the best strategy to free the hostages. Some officials said the options that the administration publicized yesterday were designed primarily to pressure Berri and his allies in Lebanon. Others said they also were intended as a signal to Americans that Reagan is actively engaged in seeking a solution to the crisis.

The president on Monday canceled a scheduled 10-day vacation to his California ranch, even though an official said yesterday he had done so with "great reluctance."

White House political advisers have been contending that domestic impatience is growing at the apparent failure of diplomatic efforts to free the hostages. However, national security affairs adviser Robert C. McFarlane and Secretary of State George P. Shultz told Reagan yesterday that these efforts still require several days to bear fruit, sources said.

Speakes, who delayed his normal noon briefing by nearly four hours yesterday while Reagan met with his advisers and members of Congress, was unspecific about how long Reagan would wait before pursuing one or more of the options. At different times in the briefing he said "a day or two," "a few days" and "several days." An official said later "there is no specific timetable."

White House officials confirmed that they were highly sensitive about the criticisms of administration efforts from some hostage family members. Officials said that at a staff meeting Monday it was decided not to bring these families to the White House for what one of them said would be "a media show."

However, Speakes said Reagan would continue to meet with hostage families on his trips around the country, as he has done in Indianapolis and Dallas.

Although the administration would prefer to stop traffic into the Beirut airport with a boycott, military options have also been discussed, ranging all the way to bombing the runways. A less dramatic military option, sources said, would be to use F14 fighters from the Nimitz flying 60 to 100 miles off Lebanon to warn off commercial airliners trying to land at Beirut.

Blockading the Lebanese coast probably would require deploying more U.S. ships than those assembled offshore unless friendly navies help. Six U.S. combat ships are now on station, with an oiler and supply ships, Pentagon sources said. Speakes said one option under consideration is stopping the flow of oil and food into Lebanon.

If Lebanon's supplies are cut by sea and air, one official said, "the road from Damascus to Beirut could become the Ho Chi Minh Trail." This was a reference to the network of roads used by Hanoi to send supplies into South Vietnam during the war there.

If contingencies outlined by Speakes are executed and enforced for any length of time, the United States is likely to resume stationing two aircraft carriers and their escorting warships off Lebanon as it did in 1983 when Marines were under fire at airport positions.