Online shoppers could find costs going up after the Supreme Court did away Thursday with a decades-old precedent limiting the ability of states to collect sales tax on certain out-of-state Internet purchases.

The 5-4 ruling called the current rules “unsound and incorrect.”

Currently, businesses shipping a product to another state where it does not have a “physical presence”– a store, office or warehouse — are not forced to collect that state’s sales tax.           

A coalition of small business owners, many offering their online goods from home offices, say their profits would evaporate if forced to comply with complex tax rules in all 50 states.

Yet a majority of the states say they are losing billions in revenue, and they are supported by many large, so-called brick-and-mortar retailers like Wal-Mart that do pay sales taxes, regardless of whether their sales are done in stores or online.

The high court ruled Thursday to overturn the prior decisions.

E-commerce now makes up about 10 percent of U.S. retail sales, according to the Commerce Department.

But several justices, in an intense hour of oral arguments on Tuesday, expressed concern about overturning the precedent, despite the fact it was decided before the digital age.

Some on the bench said Congress’ refusal over the years to act on its own was a sign the status quo should be preserved.

The Associated Press contributed to this report.