Developing mobile applications for Android is impossible without testing on real devices or their software analogues. Emulator Android Studio is a powerful tool that allows you to run and debug applications without the need to connect a physical smartphone. However, many novice (and even experienced) developers encounter problems: the emulator slows down, does not start, or is unstable. In this article we will look at how to configure it correctly, choose the optimal configuration and eliminate common errors.

It is important to understand that an emulator Android is not just a โ€œvirtual phoneโ€, but a full-fledged virtual machine with its own requirements for PC resources. The speed of project assembly, stability of work, and even the quality of testing depend on how competently you configure it. We will look at all stages: from installing the necessary components to fine-tuning optimization for weak computers.

System preparation: what is needed for the emulator to work

Before creating a virtual device, make sure that your computer meets the minimum requirements. The emulator Android places high demands on processor, RAM i video card. Here are the basic recommendations:

  • ๐Ÿ–ฅ๏ธ Operating system: Windows 10/11 (64-bit), macOS 10.14+ or Linux (Ubuntu 18.04+). 32-bit systems are not supported.
  • ๐Ÿง  Processor: Intel with support VT-x or AMD s AMD-V. Without hardware virtualization, the emulator will work extremely slowly.
  • ๐Ÿงฉ RAM: minimum 8 GB (recommended 16 GB+ for simultaneous work with Android Studio and the emulator).
  • ๐Ÿ’พ Free disk space: no less 20 GB (the emulator and system images take up a lot of space).

Pay special attention to the settings BIOS/UEFI. On most computers, hardware virtualization is disabled by default. To enable it:

  1. Restart the PC and enter BIOS (usually the key F2, Del or Esc during boot).
  2. Find the section Advanced โ†’ CPU Configuration (the name may differ).
  3. Activate the options Intel Virtualization Technology (VT-x) or AMD-V.
  4. Save the changes and reboot.
โš ๏ธ Attention: On some laptops (especially from HP i Lenovo) virtualization may be blocked at the firmware level. In this case, only updating BIOS or using alternative emulators like Genymotion.

Also make sure that you have the latest versions of Android Studio i SDK Toolsinstalled. To do this, go to Settings โ†’ Appearance & Behavior โ†’ System Settings โ†’ Android SDK and update all packages in the SDK Tools.

๐Ÿ“Š What processor does your PC have?
Intel Core i3/i5/i7
AMD Ryzen 3/5/7
Apple M1/M2
Other

Installing and configuring components for the emulator

To create a virtual device, you must first install all the required components. In Android Studio this is done through SDK Manager. Open it through the menu Tools โ†’ SDK Manager or through the icon in the upper right part of the window.

In the section SDK Platforms select the version Androidthat you plan to emulate. For most tasks, the latest stable version is suitable (for example, Android 14 or Android 13). Pay attention to the column API Level โ€”it will be needed when creating a device.

Next, go to the tab SDK Tools and install the following components:

  • ๐Ÿ“ฑ Android Emulator โ€” the main package for launching virtual devices.
  • ๐Ÿ› ๏ธ Intel x86 Emulator Accelerator (HAXM) โ€”driver to speed up work on processors Intel.
  • ๐Ÿ–ฅ๏ธ Android SDK Platform-Tools โ€” utilities for interacting with devices (adb, fastboot etc.).

After installation, restart Android Studio. If you use a processor AMD, instead of HAXM you will need to enable Windows Hypervisor Platform (for Windows) or install WHX manually. On macOS with chips Apple Silicon (M1/M2) the emulator works through Rosetta 2, but performance may be lower than on Intel.

โš ๏ธ Attention: If after installation HAXM the emulator gives an error "VT-x is not available", check whether an antivirus is blocking virtualization (for example, Avast or Kaspersky). Add Android Studio and qemu-system-x86_64.exe to exceptions.

Creating a virtual device (AVD) in Android Studio

Now let's move on to the most interesting part - creating a virtual device. To do this:

  1. Open AVD Manager through the menu Tools โ†’ Device Manager or click on the phone icon in the top panel.
  2. Click Create Virtual Device (or + Create Device in new versions).
  3. Select a device category: Phone, Tablet, TV or Wear OS.

At the next stage, you will be asked to select a specific model. Here you can go in two ways:

  • ๐Ÿ“ฑ Select real device from the list (for example, Pixel 7 Pro or Samsung Galaxy S23). This is convenient if you are testing an application for a specific device.
  • โš™๏ธ Create custom configuration with arbitrary parameters (screen resolution, pixel density, etc.).

After selecting the model, click Next and proceed to selecting the system image (System Image). It is important to consider here:

  • ๐Ÿ”„ Android version: to test new features, take the latest version, for compatibility - Android 10-12.
  • ๐Ÿ–ฅ๏ธ Image type:
    • Google Play - with services Google (needed for work with Google Maps, Firebase etc.).
    • Vanilla โ€” "clean" Android without GMS (easier and faster, but without Play Market).
  • ๐Ÿ’พ Architecture: x86_64 (recommended) or ARM (slower, but needed for testing native code).

At the last stage, specify the device name (for example, Pixel_7_API_34) and configure additional parameters:

Parameter Recommended value Explanation
RAM 2048 MB For Android 12+ it is better to highlight 3-4 GB, but not more than half of the physical RAM.
Internal Storage 4 GB Minimum for installing applications. For games or large projects, take 8 GB+.
Graphics Hardware - GLES 2.0 Optimal for most tasks. Software works slowly.
Camera VirtualScene or Webcam0 To test the camera, select a webcam or virtual stage.

After setup click Finish. The virtual device will appear in the list AVD Manager. Now you can start it with the button โ–ถ๏ธ Run.

Make sure that virtualization is enabled in the BIOS

Close resource-intensive applications (browser, games)

Allocate at least 2 GB of RAM to the emulator

Select a system image with architecture x86_64-->

Optimizing emulator performance

Even on powerful PCs, the emulator Android may work slowly. Here are a few ways to speed it up:

1. Usage Quick Boot

By default, the emulator performs a โ€œcoldโ€ start, which takes 1-2 minutes. Enable Quick Boot (quick launch) to save the device state between sessions:

  1. Open the emulator settings via โ‹ฎ โ†’ Settings in AVD Manager.
  2. Enable the option Enable Quick Boot.
  3. When closing the emulator choose Saverather than Power Off.

2. Setting up the graphics accelerator

If the emulator slows down during animations, try changing the rendering mode:

  • ๐ŸŽฎ Hardware - GLES 2.0 โ€”a balance between speed and compatibility.
  • ๐Ÿš€ Hardware - GLES 3.1 โ€”faster, but may not work on older video cards.
  • ๐Ÿข Software โ€”slow but stable (if others modes do not work).

3. Limiting resource use

The emulator can โ€œeat upโ€ up to 50% of the processor. To avoid this:

  • ๐Ÿ”ง In the file ~/.android/advancedFeatures.ini (or %USERPROFILE%\.android\advancedFeatures.ini on Windows) add the line:
Vulkan = off

GLDirectMem = on

This will disable Vulkan (which may conflict with drivers) and optimize memory usage.

4. Alternative emulators

If a standard emulator Android Studio works unsatisfactorily, consider alternatives:

  • ๐Ÿ”น Genymotion - fast and stable, but paid for commercial use.
  • ๐Ÿ”น BlueStacks - popular among gamers, but not suitable for debugging.
  • ๐Ÿ”น NoxPlayer - good for testing games, but may contain advertising.
โš ๏ธ Attention: On macOS with chips Apple Silicon (M1/M2) emulator Android works through Rosetta 2, which reduces performance by 20-30%. It is expected that in future versions Android Studio there will be native support for ARMemulation for Apple.
๐Ÿ’ก

If the emulator freezes at startup, try deleting the cache folder along the path ~/.android/avd/{device_name}.avd/cache and recreate the device.

Solving typical emulator errors

Even with proper configuration, the emulator may generate errors. Let's look at the most common ones and how to fix them.

1. Error: "VT-x is not available" or "HAXM is not installed"

Causes and solutions:

  • ๐Ÿ”น Virtualization is disabled in BIOS โ†’ enable VT-x/AMD-V.
  • ๐Ÿ”น Antivirus blocks HAXM โ†’ add an exception for qemu-system-x86_64.exe.
  • ๐Ÿ”น Hyper-V conflicts with HAXM (on Windows) โ†’ run in CMD as administrator:
bcdedit /set hypervisorlaunchtype off

After that, reboot PC.

2. Error: "Emulator: emulator: ERROR: x86 emulation currently requires hardware acceleration!"

This error occurs if:

  • ๐Ÿ”น An image is selected ARM, but there is no support for hardware virtualization โ†’ switch to x86_64.
  • ๐Ÿ”น The driver HAXM is not installed โ†’ reinstall it via SDK Manager.
  • ๐Ÿ”น On macOS there are not enough rights โ†’ give permissions in System settings โ†’ Security โ†’ General.

3. The emulator does not connect to the Internet

Problems with the network in the emulator are solved as follows:

  • ๐Ÿ”น Check the proxy settings in Android Studio: File โ†’ Settings โ†’ Appearance & Behavior โ†’ System Settings โ†’ HTTP Proxy.
  • ๐Ÿ”น Restart the DNSservice on the host machine:
ipconfig /flushdns

on Windows or

sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder

on macOS.

4. Black screen at startup

If the emulator starts, but the screen remains black:

  • ๐Ÿ”น Increase the selected RAM to 3-4 GB.
  • ๐Ÿ”น Change the graphic renderer to Software.
  • ๐Ÿ”น Delete and recreate the device with a different system image.
What to do if the emulator does not respond to the keyboard?

If the keyboard does not work in the emulator, check:

1. Layout language (can be English by default).

2. Settings in AVD Manager โ†’ โ‹ฎ โ†’ Settings โ†’ Send keyboard shortcuts to (select Emulator).

3. Conflict with apps like AutoHotkey or Razer Synapse (disable them).

Working with the emulator: useful features and hot ones keys

The emulator Android V Android Studio supports many functions that many people do not know about. Here are some useful features:

1. Hot keys

Combination Action
Ctrl + F11 / Cmd + F11 Switch screen orientation (portrait/landscape).
F2 Submit button press Menu.
Page Up / Page Down Increase/decrease volume.
Esc Return to home screen.

2. Drag and drop files

You can drag files (for example APK or images) directly into the emulator window. They will automatically appear in the folder /sdcard/Download/.

3. Virtual sensors

To test applications with sensors (gyroscope, accelerometer), open Extended Controls (button โ‹ฎ in the emulator panel) and go to the Sensortab. Here you can:

  • ๐Ÿ“ฑ Simulate device tilts.
  • ๐Ÿงญ Enter coordinates GPS.
  • ๐Ÿ”‹ Simulate battery charge level.

4. Screenshots and screen recording

To take a screenshot, click Ctrl + S (or Cmd + S on macOS). To record a video:

  1. Open Extended Controls โ†’ Screen Record.
  2. Click Start Recording.
  3. When finished, click Stop โ€”the video will be saved in format WebM.

5. Connecting to ADB

The emulator automatically connects to ADB (Android Debug Bridge). To check the list of connected devices, run in the terminal:

adb devices

You will see something like:

List of devices attached

emulator-5554 device

Now you can send commands, for example:

adb -s emulator-5554 install app.apk
๐Ÿ’ก

Use adb to quickly install APK, copy files and log. This will save time compared to manual actions in the emulator.

Emulator vs real device: which is better for testing

The emulator and physical devices have their pros and cons. Let's compare:

Criteria Emulator Real device
๐Ÿ’ฐ Cost Free Purchase required devices
โšก Deployment speed Instant launch (s Quick Boot) Requires connection via USB/Wi-Fi
๐Ÿ› ๏ธ Hardware testing Limited (no real sensors, cameras, etc.) Full support for all functions
๐Ÿ”„ Flexibility configurations Any resolutions, versions Android, architecture Depends on the device model
๐Ÿž Bug search Good for logical errors and UI Necessary for testing performance and compatibility

For full testing, it is recommended to use both an emulator and a real device. The emulator is suitable for quick debugging and interface testing, and a physical device is suitable for testing performance, working with the camera, GPS and other hardware functions.

If you do not have a real device, you can use cloud testing services:

  • ๐Ÿ”น Firebase Test Lab โ€” free test on devices Google.
  • ๐Ÿ”น BrowserStack โ€” platform with a wide selection of devices.
  • ๐Ÿ”น AWS Device Farm โ€”cloud testing from Amazon.

FAQ: Frequently asked questions about setting up an emulator

๐Ÿ”น Why does the emulator slow down even on a powerful PC?

The most common reasons:

  • Hardware virtualization is not enabled (VT-x/AMD-V).
  • Too little allocated RAM (increase to 3-4 GB).
  • Using image ARM instead x86_64.
  • Conflict with antivirus or other virtualization apps (VirtualBox, VMware).

Also try disabling Vulkan in the file advancedFeatures.ini.

๐Ÿ”น Is it possible to run the emulator without Android Studio?

Yes. The emulator is a separate application emulator.exe (or emulator on macOS/Linux). To run it manually:

  1. Find the path to the emulator (usually ~/Android/Sdk/emulator/emulator).
  2. Run the command:
emulator -avd Name_of_your_AVD

The list of available devices can be obtained with the command:

emulator -list-avds
๐Ÿ”น How to transfer the emulator to another PC?

The folder with virtual devices is located on the path:

  • Windows: %USERPROFILE%\.android\avd\
  • macOS/Linux: ~/.android/avd/

Copy the folder with the desired device to the new PC and open it via AVD Manager. If the emulator does not start, check the paths to SDK in the file config.ini inside the folder AVD.

๐Ÿ”น Why is there no Google Play in the emulator?

You selected a system image without services Google. To fix:

  1. Delete the current device in AVD Manager.
  2. Create a new one by selecting the image marked Google Play (for example, x86_64; Android 13.0; Google Play).

Please note that such images weigh more and require more resources.

๐Ÿ”น How to change the language in the emulator?

To change the language:

  1. Open Settings in the emulator.
  2. Go in System โ†’ Language and input โ†’ Languages.
  3. Add the desired language and move it to the first place.

If the desired language is not in the list, it may not be supported by the selected version Android.