Block Android OEMs data collection + ads with Steven Black's Unified Hosts.
-
Install the latest version of AdAway.
-
Inside adaway app, Preferences >> Enable systemless mode >> Reboot
-
Open adaway app, Preferences >> Redirection IPv4 >> Change the value to 0.0.0.0
-
Go to >> Hosts sources >> replace existing url with:
https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
-
Home >> ENABLE AD-BLOCKING >> reboot required for change to take effect
- Skip step 2 if you aren't using Magisk.
AdGuard DNS is a free, privacy-oriented DNS resolution system that blocks tracking, ads and phishing. More information here.
- Make a new shell script file
.sh
containing this script:
#!/system/bin/sh
iptables -t nat -A OUTPUT -p tcp --dport 53 -j DNAT --to-destination 94.140.14.14:53
iptables -t nat -A OUTPUT -p udp --dport 53 -j DNAT --to-destination 94.140.15.15:53
iptables -t nat -I OUTPUT -p tcp --dport 53 -j DNAT --to-destination 94.140.14.14:53
iptables -t nat -I OUTPUT -p udp --dport 53 -j DNAT --to-destination 94.140.15.15:53
-
Place the script file into
/data/adb/service.d
and set755
as permissions. -
Reboot changes to take effect.
or you can just download it from here: https://gist.github.com/AzimsTech/c20512b2b15763bc2677a9426266e281 and run setup.cmd
you can skip all steps from here
- Requires Magisk
- An automated method requires adb for your pc