Licensing a Plugin [closed]

The only 100% way to get a paid subscription kind of service working is to move part of the functionality to an external server which is under your control and manage payment, expiry, etc there.

When the code is not under your control you can not limit its use, this is a very basic life fact of software development, especially when the source code can be easily modified. “Calling home” by itself doesn’t really help much if I can edit the code and remove the check without hurting the functionality.

Since you can not prevent “bad users” from manipulating your code it is better to avoid thinking too much about protection. If your plugin will provide actual service in a good price point then most people will be willing to pay for it instead of wasting time on pirating it.