A blocking solution I've found very effective for android is dns based. It sets up a vpn connection and allows you to edit the host files that get listed on the device.
https://github.com/julian-klode/dns66/releases
Since Android 9 you can setup a DoH (DNS over HTTPS) even without the vpn loophole. The setting is called "Private DNS" and may be even more battery-preserving.