WASHINGTON (AP) _ An appeals court today overturned a federal regulation that cleaner burning gasoline contain corn-based ethanol, a ruling that could cost farmers and ethanol processors hundreds of millions of dollars.

The three-judge panel concluded that while the Environmental Protection Agency had ``the authority to set a standard'' for cleaner gasoline under the 1990 Clean Air Act, it could not ``mandate the manner of compliance or the precise formula'' for the fuel.

Last year, the EPA directed that cleaner burning gasoline, which was required beginning this year in urban areas with the worst smog problem, contain ethanol as a oxygenate to make the fuel burn with less pollution.

Under the EPA regulation, at least 30 percent of the oxygenate used in the gasoline had to be ethanol, a product that is processed from corn. The rest could be a petroleum-based methanol derivative called MTBE.

The EPA formula could require as much as 650 million gallons, or $1.5 billion worth of ethanol annually for reformulated gas, according to agriculture industry estimates.

The petroleum industry challenged the ethanol mandate in court. Last September, the U.S. Court of Appeals directed that the ethanol program be put on hold, awaiting a final ruling.

The farming industry had lobbied extensively in Congress and within the Clinton administration for the ethanol mandate.

The farmers have argued that without a federal mandate, ethanol would never see a significant share of the reformulated gasoline market, which is dominated by the petroleum industry.

The reformulated gasoline requirement went into affect Jan. 1, but with no mandate for ethanol. Although the ethanol additive is being used in some parts of the country, but most refiners use MTBE as the oxygenate.

EPA officials were not available immediately for comment. It was not certain whether the EPA would appeal the decision to the U.S. Supreme Court, but some legal experts have said such an appeal is unlikely.

Since January, reformulated gasoline has accounted for about a third of all the gasoline sold in the United States, according to the EPA. While a limited amount of ethanol is used as an oxygenate, mostly in Midwest states, refiners predominantly use MTBE.

Both additives increase the gasoline's oxygen content, allowing the fuel to burn cleaner. The EPA estimates reformulated gasoline reduced smog-causing pollution by 20 percent reduction.

Under the 1990 Clean Air Act, the cleaner burning gasoline must be sold in nine cities with the worst smog problems: New York, Los Angeles, Chicago, San Diego, Baltimore, Milwaukee, Houston, Philadelphia and Hartford, Conn. Other parts of the country in 14 states _ including much of the Northeast _ voluntarily have joined the program.

The lawsuit challenging the ethanol mandate was filed by the American Petroleum Institute, which represents the major oil companies, and the National Petroleum Refiners Association.

Petroleum industry lawyers argued that the EPA's requirement was a ``massive promotion of the ethanol industry'' without additional benefit to the environment.

However, the Justice Department, representing the EPA, maintained that the required ethanol use was part of the government's attempt to reduce U.S. dependence on fossil fuels, particularly imported oil.