This is extremely common at gas stations and coffee shops, for example.
What's the difference? If the business advertises both a cash price and a credit card price, then there is effectively no difference I believe whether you characterize it is a discount for cash or a surcharge for credit cards.
However, if you only advertise one price, then its a surcharge if that is the cash price and you add extra for credit cards at the register. If the one price is the credit card price, and you take off some for cash at the register, then it is a cash discount.
Doing a cash discount was a common trick at gas stations to work around terms in their contracts that said they would not have credit card surcharges. There was a lawsuit against such contract terms by merchants who wanted to do a surcharge, and in a settlement in 2013 Visa and Mastercard agreed to allow them (with some restrictions, like no more than 4%, must be a sign disclosing them at the point of sale, had to be included on the receipt, and had to apply to all cards), reducing the need for such tricks in many areas.
There are some states that have laws prohibiting credit card surcharges, so the cash discount trick may still be in use there. California, Colorado, Connecticut, Florida, Kansas, Maine, Massachusetts, New York, Oklahoma, and Texas. These have been challenged on Free Speech grounds. The Supreme Court has said that they are (well, New York's version, but others are similar) is a regulation of speech, but did not rule whether it was an unconstitutional regulation (the lower courts had not reached that issue) [1]. I don't happen to know what happened to that case after that.
[1] https://www.supremecourt.gov/opinions/16pdf/15-1391_g31i.pdf
For some transactions the reality is that almost every single purchase will be on a card and the vendor knows it, so advertising a "cash" price was just always going to be misleading. Rather than try to figure out some complicated rule (maybe you can advertise the cash price if most customers pay in person at a store?) the authorities just said it's simpler to ban all fees.
The British news media actually did stuff about this in the last few days. A bunch of famously shady lines of business like letting agencies were still charging extra for credit cards even though that's illegal.
Why not? Is that due to contract terms that prevent you from charging more for card transactions vs other payment methods?
I vaguely remember clauses like that were recently thrown out in the USA. Iād imagine the EU would be even more consumer friendly.