How do shareholders benefit from derivative actions?

Any relief granted pursuant to a derivative action is a judgment against a third person requiring them to pay money to, or make changes for, the benefit of the corporation. If money is recovered as a result of a derivative action, it would be paid back to the corporation, which could have a positive effect on the company's stock price and benefit all current shareholders.