WASHINGTON (Reuters) - The U.S. Supreme Court on Tuesday struggled over how to decide a challenge to a state law barring retailers from charging more to buy with credit instead of cash, debating whether it merely regulates prices or violates merchants’ constitutional rights.

Slideshow ( 2 images )

The eight justices heard an hour of arguments in an appeal brought by merchants to a lower court’s ruling upholding the New York law, which is similar to statutes in nine other states.

Merchants contend these laws infringe on their free speech rights guaranteed by the U.S. Constitution by dictating how they describe their pricing to customers.

Retailers are forced to pay fees to credit card companies every time a customer buys with a card. The law bars retailers from imposing a surcharge on customers who make purchases with a credit card. It also makes it impossible for merchants to call fees paid to credit card companies a surcharge that is added to the price of a product. The law does not stop retailers from offering a discount for cash purchases.

The justices debated whether the law even regulates speech or whether it is a traditional form of price regulation that is not subject to a free speech challenge.

Several justices including Stephen Breyer indicated they did not think the law affects free speech, suggesting they may vote to uphold it. Breyer said the law simply requires retailers to post a price that includes the credit card surcharge.

“What’s that got to do with speech?” Breyer asked.

Other justices appeared to have concerns that the law could burden free speech. The state is “forcing the merchant to speak in a particular way,” Justice Samuel Alito said.

Likewise, Justice Anthony Kennedy noted that a retailer could be subject to criminal penalties simply for displaying “truthful information.”

An option raised by Alito is for the justices to send the case to the New York state courts to clarify what the law means under state law rather than decide it in federal courts.

Retailers have long complained about the cost of accepting credit cards including "swipe fees," a percentage of a credit card transaction the merchants pay to networks such as MasterCard IncMA.N and Visa IncV.N every time a credit card is swiped to pay for a purchase.

“Swipe fees” average about 2 percent of a purchase, according to the National Retail Federation.

The surcharges that merchants impose can pass the cost of the “swipe fees” on to consumers and are worth billions of dollars a year to credit card companies

The New York law subjects merchants to a potential one-year prison sentence and $500 fine for imposing credit card surcharges.

Five merchants, including a Brooklyn ice cream parlor and a hair salon near Binghamton, challenged the law.

In 2013, U.S. District Judge Jed Rakoff sided with the merchants and blocked enforcement of the law. The New York-based 2nd U.S. Circuit Court of Appeals then upheld the law in 2015.