Why not tax or make all energy more expensive? That way all wasteful usage will be curtailed and only the valuable use cases will be left after a while. If we do what you proposed it sounds like we should start taxing other behavior on the internet based on its usefulness to society and electricity usage.
We definitely should tax all dirty energy, and the shifting price landscape will do a lot to fix the environmental issues we're facing.
That said, it's not enough - because the market isn't some NP-complete-problem-solving magic oracle. It's just a greedy optimization algorithm. It's very prone to falling into bad local optima. We know that for a fact, that's the basis of most regulations around markets. Left unattended, the market would happily prioritize mining Bitcoin over producing food, as running Bitcoins in circles is more profitable than selling grain - up until there's an actual shortage of food and the market self-destructs.
Energy on it's own is not dirty or clean. You cannot test the wires in the wall to say yep, this energy is clean.
You can of course tax the energy producers, but that does not prevent fraud on it's own - see oil tankers converting gas pollutants to water and causing even more harm.
You purchase electricity with clean production guarantees.
That doesn't necessarily mean the electricity you use comes from that, or any, clean source, but that clean sources are used to contribute to grid supply equally.
If that's not actually happening then we can call that fraud, but that's a separate issue.