Non-destructive trial/preview limitations of the content for unlicensed users sounds pretty legal. This isn't even obfuscated, as most DRM/License schemes will be.
That said, they may sue or counter sue you, which is often a dumb move but by not paying you that have demonstrated sketchy behavior.
Additionally depending on what country you are in this can also be a an offense according to various computer crime laws which means you are not only risking a committing a felony but also being unable to work if the law where you live allows the state to bar you from using a computer.
Honestly, the idea that you're supposed to just shrug and say "Okay, fine I guess" is a self-defeating unprofessional attitude.
Clients are not doing you a favour by allowing you to work them.
If you sell someone an object, they don't get legal possession until they complete payment for it. (Try to not-pay a house or car loan and see how far you get.)
Software services should be no different. There may be more negotiation involved, especially with a genuinely struggling business with good intentions. But deadbeats are deadbeats. Removal of product or service is completely legal and morally valid.
Just look at all the hosting companies which redirect to a page when you stop payment.
A hosting company has a clause in the contract which states they can terminate service after X days if a payment hasn't been cleared, this isn't the same thing unless you make the contract a service contract in which case you can terminate the service.
No one would sign a contract that says that they get some one time restricted license of the website or w/e they paid to you make which can be revoked because you hold the ownership.
You can't pay off 98% of a mortgage and call it enough, they own the house until they receive the final payment. (Second mortgages are a little different.)
In any case, it would obviously not change the fact that it would probably be a terrible idea to do something like this, ever.
In fact you have to be the sole owner of everything in that chain for this to be considered even remotely legal, this includes things like the domain and certificate. And even then it's not that simple since legal ownership isn't the only thing that plays a factor here since the client can claim beneficial ownership which grants them certain rights.
It is perfectly legal for you to mangle your own web site. Even if it's a site you made at someone else's request.
If they haven't paid, they don't own it, and they have no right to complain.
A UK contractor was prosecuted many years ago for putting a time bomb in software he wrote and was never paid for.
It remained his software but it was running on their computer. When it ceased to function that was considered to be an authorised change to their system under the computer misuse act. And he was found guilty of a criminal offence.
Websites are a bit more of a grey area. Whose server is it? Who's paying for it? Who owns the domain? Whatever the answer to these questions, it's not clear how a judge would decide it.
Bottom line: unless your contract makes very clear that your software/website/whatever will cease to function on a particular date you could be looking at time in prison.
The best thing to do is if you also operate the website (hosting it on a VPS which you pay for) as part of the contract just terminate the service in accordance to the SLA in the contract, if you do not host the website do not do anything to it just seek legal action.
I mean, who would say into your face that they don't want to pay you for your work? (what not signing such a contract actually implies)
If i steal your TV and you break into my house to take it back you've committed a felony.
Or a better example if you've sent me a TV and I didn't pay you you can't break into my house to claim it back even if the contract we signed states that it is yours until paid in full. This is why a bank needs to get an order to repossess your car or house they can't just take it away even if it's leveraged, we have laws.
Under Texas law, your vehicle may be repossessed even if it is "only" late. That means that if you payment was due on November 1st and you haven't paid by November 10th it is possible to find your vehicle was repossessed by the 11th of November. The Financer or Leaser does not need to go to court in order to repossess you vehicle, nor are they required to give you advance warning. The repo man is allowed to come onto your property to repossess you vehicle; but they are not allowed to disturb the peace to do so. Also, if your repo man needs to come onto your property to repossess your property, they are not allowed to destroy or damage you property to carry out the repossession.
A judge may order the copy of your work taken offline or destroyed, yes.
But you can't take matters into your own hands and do that without going to court.
You do not own the (unlicensed or otherwise) copies of your work that have already been transferred to others, and going onto their server to destroy/modify the site is not only a civil wrong on your part, but a crime under the Computer Fraud and Abuse Act.
If a client doesn't pay you respond by denying access to the service - which is exactly the same as a hosting company turning off a server for non-payment of hosting fees.
I wouldn't do the fade thing, because while it's entertaining it's rather juvenile. But I would be completely happy to delete all work from a client's server and restore it to its previous state if it's obvious they have no intention of ever paying.
This is normal behaviour for a business. Generally if someone tries to default on payment, they can expect goods to be reclaimed and services to be terminated.
The fact they're running a business and you're a contractor doesn't change that. You're running a business too. If they don't understand that, save yourself the grief and don't work with them.
You "deleting all work from a client's server" are accessing someone else's property, and doing it for destructive purposes. That's illegal, both civilly and criminally. They're not analogous situations.
Even in the physical world, repossession companies may not enter a private building without permission. "Goods are reclaimed" by a sheriff carrying out a court order, not by whoever is owed money breaking in and taking things on their own volition.