0

Is there a method to modify the hosts file on an Android device running version 13 without root access?

I'm interested in altering hosts file to manage network configurations and block certain websites, but I'd prefer not to root my device due to potential security and warranty concerns.

Are there any legitimate and safe procedures, ADB commands, or tools available for achieving this on Android 13?

I couldn't find any way to do that.

Andrew T.
  • 15,988
  • 10
  • 74
  • 123
  • 1
    The answer is no, but you could create a vpn interface and filter on the list of unwanted routers. –  Oct 09 '23 at 16:50
  • 1
    What do you want to do? Black sites like ad sites? Or redirect traffic to a different server for app testing? – Robert Oct 09 '23 at 17:02
  • 2
  • @Robert for ad blocking. now I'm using vpn based blocker, but it's not good like old host based one. – almahmud Oct 11 '23 at 10:16
  • Not sure what you mean by "it's not good like old host based one". I use VPN based blockers like Blokada 5 for years, they work like a charm. – Robert Oct 11 '23 at 10:51
  • @IrfanLatif , Yes, this is what I was looking for. However, since the discussion in the link is 6 years old, I was hoping if there was any new way to do it. But anyway, thanks. – almahmud Oct 11 '23 at 10:53
  • @Robert Actually, in this case, another app keeps running in the background, so it is a bit uncomfortable. It also drains the battery. However, the new Android private DNS system is definitely better in this regard. – almahmud Oct 11 '23 at 10:57
  • Welcome to the Q&A site Android Enthusiasts Stack Exchange. Regarding Irfan Latif's linked Q&A, have you tried any of the answers? Note that while the question was asked in 2017, there was an answer posted in 2022. – Andrew T. Oct 13 '23 at 01:40
  • @AndrewT. Yes, I have tried all of the answers that are applicable to a usual non-rooted phones. The only thing left to do is to unlock the bootloader and change/replace the hosts file from recovery. This may void the warranty, so I'm thinking of waiting a few more days. Thank you for your help. – almahmud Oct 14 '23 at 09:46

0 Answers0