Here is a simple solutions: porn sites use a .xxx domain or some such, and browsers can trivially be configured to block that domain.
I'd be fine with government enforcing such a rule.
But years and years after we started talking about such a solution, we don't have it, but instead have intrusive privacy distroying solutions that don't see to even address the problem.