Running Android Emulator Without Android Studio on MacBook

Jerry PM
3 min readAug 28, 2023

--

This is how I run an emulator on Macbook

Source: Author

I am currently developing a Flutter application. Right now, I am frequently using VSCode for app development, so it’s cumbersome for me to open Android Studio first to run the emulator. Here, I am sharing a tip for those who want to use the emulator without having to open Android Studio.

To run the Android Emulator without having to open the entire Android Studio, you can follow these steps on your MacBook:

Install Android Studio:

If you haven’t installed Android Studio yet, you need to do so. You can get it from the official Android Studio website.

Install Android Emulator:

After you have installed Android Studio:

  • Open Android Studio.
  • Open “Preferences” (usually in Android Studio > Preferences ).
  • In “Preferences”, select “Appearance & Behavior” > “System Settings” > “Android SDK”.
  • In the “SDK Platforms” tab, make sure you have selected the desired Android platform.
  • Switch to the “SDK Tools” tab.
  • Make sure you have selected “Android Emulator” and click “OK” to install it (if not installed already).
Source: Author

Create AVD (Android Virtual Device)

  • From Android Studio, select “Tools” > “Device Manager”.
Source: Author
  • Click “Create Virtual Device”, select the desired device type, then choose the desired system image (for example: Pie, Oreo, etc.).
Source: Author
  • Complete the AVD creation process.
  • Run the Emulator Without Opening Android Studio: After you have created the AVD, you can run it without opening Android Studio by using the Terminal. Follow these steps:
  1. Open Terminal.
  2. Enter the following command to navigate to the directory where the emulator is located
cd ~/Library/Android/sdk/emulator

3. You can check the list using the command

./emulator -list-avds

4. To run the emulator, enter the command. Change NAME_AVD with the name of the AVD you have created. If you are not sure about the name of your AVD

./emulator -avd NAME_AVD

// example

./emulator -avd Pixel_4_API_33_1

After that, you can use an emulator without opening Android Studio 😊

Update 8 July 2024

When running the simulator, if you get a black screen and restarting the MacBook and reopening the simulator doesn’t fix it, you can resolve the issue by cleaning the simulator using the -wipe-data option.

➜  emulator ./emulator -avd Pixel_7_API_VanillaIceCream -wipe-data

Conclusion

In summary, you can run Android Emulator on a MacBook by setting up Android Studio, installing Emulator, and using Terminal commands.

--

--