A variable-speed pool pump can save meaningful electricity, but it introduces electronics (drive/controller) alongside traditional pump wear. Common failures include motor bearings, shaft seals that leak and damage the motor, drive/control modules, and impeller clogs that strain the system.
Repair is often worthwhile when the pump wet-end is in good shape and the fix is a seal kit or bearing/motor service under the threshold, because replacing a VS pump is expensive. Replacement becomes more attractive when the drive/controller fails out of warranty, the motor has been water-damaged by a long-term seal leak, or repeated overheating occurs-those tend to be costly and may recur.
Also consider your pool schedule: if the pump runs many hours per day, reliability has high value. If multiple repairs are needed and the pump is older, replacement can restore efficiency savings and reduce the risk of mid-season downtime.