Piracy is no way preventable. But you can compete with free. All you need is reliable legal services at least as easy and comprehensive as the pirate alternatives. And Spotify is all that.
But having solved this, artist are still not getting paid more. That’s because piracy was never the problem. Record labels were always getting money off the top, leaving the artists with little to no money. But now that streaming has become dominant, labels have become even more powerful. Artists get 10%, while labels get 73% out of every play.