Internet stopped working on Android Emulator (Mac OS)
I think the problem is related to the DNS settings my company is using.
To get network access for my emulator, I needed to run the emulator with the same corporate DNS server specified.
I'm on a Mac, so I first checked my network settings to find that my DNS was set:
System Preferences -> Network -> Wi-Fi -> Advanced -> DNS
Then navigate to the location of the SDK emulator (for convenience):
cd ~/Library/Android/sdk/emulator
Then the available emulators are listed:
./emulator -list-avds
Then I started the desired emulator with overriding the DNS server:
./emulator @<emulator_name> -dns-server <dns.server.ip.address>
It would be nice if I could configure this DNS for use by emulators running through Android Studio, but hopefully these steps will help someone else in a similar situation.
source to share
Couldn't find a solution by configuring network settings. So added a new virtual device from Tools -> Android -> AVD Manager by downloading a new system image (Android O, API 26). And now it works.
If you want to use the same API level, make sure you delete the existing system image and download it again.
source to share