In a ruling that may mean a windfall for states, the Supreme Court held yesterday that private contractors operating facilities for the government are not immune from state taxes.

The federal government had challenged the state of New Mexico's tax policies, claiming that certain contractors who do business with them are instruments of the United States and are immune from state taxes just as the federal government is.

But the justices, in a unanimous ruling, said the contractors are not identified as agents by the government and are independent taxable entities. In the New Mexico case, the contracts involved were advanced funding, meaning the contractors draw directly from U.S. Treasury funds for their costs associated with the government work.

"Indeed, immunity cannot be conferred simply because the tax is paid with goverment funds," wrote Justice Harry A. Blackmun in the court's opinion. Previous cases conclude "that tax immunity is appropriate in only one circumstance: when the levy falls on the United States itself or on an agency or instrumentality so closely connected to the government that the two cannot realistically be viewed as separate entities at least insofar as the activity being taxed is concerned."

If the government's position were valid, "virtually every federal contractor is or could easily become immune from state taxation," the court said.

The federal government's immunity to state taxation was established in an 1819 decision in which the Supreme Court said that "the power to tax involves the power to destroy."

The financial windfall available to states where contractors do federal work will vary depending on the number and value of the contractual arrangements. But federal officials said the government may owe the state of New Mexico more than $100 million in back taxes and $20 million annually in the future.

In 1967 New Mexico changed its taxing policy and sought to impose the taxes on private businesses. However, the federal government opposed the move because such taxes would be included in its procurement costs. The government won in federal court but that decision was overturned by the 10th U.S. Circuit Court of Appeals.

The Supreme Court, affirming the appeals court ruling yesterday, stressed the difference between a private contractor working for the government and a government entity.

"Their relationships with the government have been created for limited and carefully defined purposes. Allowing the states to apply use taxes to such entities does not offend the notion of federal supremacy."