Almost nobody believes crude oil really is worth $40 a barrel.

But there it is, trading at record heights on the New York Mercantile Exchange. Crude oil has been propelled to dizzying levels by speculation that the standoff in the Persian Gulf could at any moment escalate to a shooting war that would shut down Saudi Arabia's rich oil fields, with catastrophic results for the world oil supply and, in turn, the global economy.

The high-quality crude that is traded as a benchmark on the New York exchange closed Friday at $39.51 a barrel, down 3 cents from the previous day, but still nearly double its price of two months ago -- an increase that has left even veteran oil-market watchers scratching their heads.

Analysts said there simply is not enough of a shortage of oil to justify such a sharp increase in prices. By all accounts, current world oil demand does not greatly exceed supply: The oil lost to the embargo of Iraqi and Kuwaiti oil and Iraq's occupation of Kuwait is mostly being made up by other petroleum-producing nations. And in any case, petroleum inventories are at relatively healthy levels.

But there is another force at work: fear about the future, a future in which war creates an actual shortage. It is the anticipation of a shortage, rather than an actual deficit, that is driving up oil prices.

"The problem right now is that mathematically the market is in balance. Psychologically it's in imbalance," said John Lichtblau, executive director of the Petroleum Industry Research Foundation, a New York consulting firm. "It's a strange situation."

"These are the prices you should see after one of the Saudi wells gets blown up," said Cynthia Kase Pedota, manager of oil risk at New York's Chemical Bank. "It's pretty absurd, if you ask me."

Still, most experts said it is wrong to treat the prices as if they are at artificial levels. As long as oil is allowed to trade freely on the commodities exchange, the price of oil is what the market says it is, some experts said, regardless of how it got there.

"It's a free-flowing market," said William Hermann, chief economist at Chevron Corp., the San Francisco-based oil company. "There are people down there in the {trading} pits bidding and selling, and they're putting real money on the line. So the market is telling you what a very competitive, free-market force is putting on the price. The price is real because you have people paying that price."

In recent weeks, the price of oil on the New York Mercantile Exchange has become as closely watched an economic barometer as the Dow Jones industrial average, even though only a fraction of the world's oil is traded on the exchange. The cost of much of the oil that refiners buy each day is based on the price that traders set on the Nymex because the exchange provides the most open and reliable test of market supply and demand.

Prices of gasoline and heating oil on the exchange have moved up along with crude oil -- each increase of $1 a barrel for oil adds 2.5 cents to a gallon of gasoline at the pump -- although retail gasoline price increases have been limited by most oil companies for political reasons.

That the actions of a small band of traders at a commodities exchange in New York can have such a potentially devastating effect on the world economy is beginning to raise questions among policy makers about whether this is the best way to set oil prices.

Others argue that the situation today is an example of the free market at work, no matter how illogical it seems. The alternatives, they said, are back-room deals, the Organization of Petroleum Exporting Countries and lines at gasoline stations.

The rapid price increase has led President Bush and other government officials to charge that the oil market is being driven by unwarranted speculation. There have been suggestions, so far unfounded, that oil companies are attempting to manipulate the market to drive prices higher or that amateur speculators in search of a quick monetary killing are helping to trade up the price.

Even some supporters of the free market have become uncomfortable with its performance in the current crisis and have been drawing a distinction between the behavior of oil company traders on the one hand and the behavior of the speculators, or "Wall Street refiners," on the other.

"Nobody really believes these phony prices set by traders in New York," said Rep. W.J. "Billy" Tauzin (D-La.), an oil industry supporter.

"If you look at the Nymex volume," one oil trader said, "you'll see a relatively modest level of contracts being traded. The speculation is thinly based. Not too many people in the oil industry are writing commitments at that price level."

But almost nobody is selling oil at that price level, either. Professional oil buyers are hanging onto any oil they already have out of fear that tensions in the Persian Gulf will escalate into a damaging war that could cause a major supply disruption, potentially catching an imprudent oil buyer short. Without many sellers, simple forces of supply and demand forces are pushing the price higher.

"It's a white-knuckle fear," said Thomas Blakeslee, an oil analyst with Pegasus Econometrics Group Inc. in Hoboken, N.J. "You've got to go with the trend right now."

"If you felt that you didn't know where your next barrel of oil was coming from, what would you do?" said Tom Bentz, director of trading for United Energy in New York. "You'd have to pay for it and make sure that you have it."

The powerful upward strength of the market was demonstrated last week when the Bush administration made an attempt to put a damper on the oil price rise by announcing plans to release a small amount of oil from the nation's 590-million-barrel Strategic Petroleum Reserve.

But the market ignored the president's effort. The amount of stockpiled oil that the administration decided to sell was was so small -- 5 million barrels, much less than the United States uses in a day -- that oil prices were hardly affected and rose to a record level within hours of the announcement Wednesday of the planned sale of reserves. Embarrassed, the administration reversed itself and said it never expected the reserve release to influence prices.

Many in the oil industry expect the government to try to take other actions to force down prices. Already, there have been calls on Capitol Hill for tighter regulations on the oil futures markets to drive out speculators and rumors have swirled in the oil market last week that some sort of regulatory action is forthcoming.

But a spokesman for the Commodities Futures Trading Commission said Friday that the agency was not considering any other actions to rein in the oil market. "We feel the market is accurately reflecting the forces of supply and demand," he said.

If oil prices were to remain at $40 a barrel for an extended period of time, according to estimates by administration and private economists, the U.S. inflation rate could rise to as much as 8 percent and plunge an already weak economy into a recession.

Given the current supply and demand equation, and without the accompanying world tension, analysts said, the price of oil probably should be in the neighborhood of $25 a barrel or less.

"I would think if the war ended immediately, if Saddam Hussein was ousted, you could probably see $10 come out of the price almost immediately," Bentz said. And if the price fell by that much, a number of those speculating on war would lose heavily.

While $40-a-barrel oil theoretically anticipates a worst-case scenario, there is little doubt that if war breaks out and the Saudi oil fields are threatened, the price could zoom still higher, probably to $50 or $60 a barrel or more.

In the meantime, "it's going to stay in this {price} range for the time being because nobody knows what will happen next," Lichtblau said. "The market is predictable now. Everything that's negative, the market believes in; everything that's positive, in terms of making supplies available, the market looks upon with some suspicion."

Staff writers Thomas W. Lippman and John M. Berry contributed to this report.