I use Home Assistant, and install that on all my old, re-purposed smartphones (usually as cheap CCTV). Each phone is plugged into a smart power socket.
I then use automation to turn a phone’s charger off when it hits 80%, then back on when it reaches 50%. No overcharging, no overheating, and actually helps keep the batteries in good shape.