How to fix Android emulator-5554 offline in adb devices
Codemia Knowledge Hub ·
"emulator-5554 offline" means ADB (Android Debug Bridge) cannot communicate with your running emulator. The fastest fix is to restart the ADB server with adb kill-server && adb start-server, then check adb devices. If the emulator is still offline, cold boot it or resolve a port conflict.
What emulator-5554 refers to
Emulators talk to ADB over localhost TCP ports. Each instance uses a pair of consecutive ports: an even-numbered console port and the next odd-numbered ADB port.
| Emulator Instance | Console Port | ADB Port | Device Name |
| First | 5554 | 5555 | emulator-5554 |
| Second | 5556 | 5557 | emulator-5556 |
| Third | 5558 | 5559 | emulator-5558 |
emulator-5554 is the first instance. "Offline" means the ADB server on your host can see the emulator process but cannot establish a working data connection to the ADB daemon inside the emulator's Android OS.
Checking the current state
If it shows "offline", work through the fixes below in order.
Fix 1: restart the ADB server
This resolves the issue in roughly 70% of cases. ADB's internal state can get corrupted, and a clean restart resets all connections:
If the status is now "device", you can deploy and debug as normal.
Fix 2: cold boot the emulator
The quick boot snapshot can hold stale ADB connection state. A cold boot starts Android from scratch.
From Android Studio:
- Open the Device Manager (formerly AVD Manager).
- Click the dropdown arrow next to your AVD.
- Select Cold Boot Now.
From the command line:
Cold boot takes longer than quick boot (30-60 seconds vs 5-10 seconds) but eliminates snapshot-related connection issues.
Fix 3: wipe data
If the internal state is corrupted beyond what a cold boot fixes:
From Android Studio: Device Manager > dropdown arrow > Wipe Data, then start the emulator.
This resets the emulator to factory state, so you lose any installed apps and data on it.
Fix 4: resolve port conflicts
Another process may hold port 5554 or 5555 and stop the emulator from binding:
Kill that process, or start the emulator on a different port:
A previous emulator that did not shut down cleanly can also leave a zombie process holding the port:
Then restart ADB and launch the emulator again.
Fix 5: check system resources
The emulator needs significant RAM and CPU. On a resource-constrained machine, its ADB daemon may not respond within ADB's timeout.
- Close other memory-intensive applications (browsers, other IDEs).
- Reduce emulator RAM in AVD settings (2 GB is usually enough for testing).
- Use a smaller screen resolution AVD (for example Pixel 4a instead of Pixel 6 Pro).
- Enable hardware acceleration (HAXM on Intel, Hypervisor.Framework on Apple Silicon, KVM on Linux).
Fix 6: update SDK Platform-Tools
An outdated ADB can have compatibility issues with newer emulator images:
Or in Android Studio: Tools > SDK Manager > SDK Tools tab > check Android SDK Platform-Tools > Apply.
Fix 7: check firewall and VPN
Firewalls or VPN software can block the localhost ports ADB uses:
On a corporate VPN, try disconnecting and restarting the emulator. Some VPN clients modify routing tables in ways that break localhost communication.
| Step | Command | Expected Result |
| 1. Check device status | adb devices | Shows emulator with "device" status |
| 2. Restart ADB | adb kill-server && adb start-server | Server restarts cleanly |
| 3. Cold boot emulator | Close and relaunch with cold boot | Emulator boots fresh |
| 4. Check port conflicts | lsof -i :5554 | No conflicting processes |
| 5. Check resources | free -h or Activity Monitor | Sufficient RAM available |
| 6. Update tools | adb version | Latest platform-tools version |
| 7. Check firewall | Test telnet localhost 5555 | Connection established |
Running several emulators at once
Each emulator needs its own port pair. If you assign ports explicitly, avoid overlaps:
Things that keep the emulator offline
Killing ADB during a deploy. If Android Studio or Gradle is deploying, adb kill-server mid-operation can leave both the IDE and the emulator in a bad state. Wait for the deployment to finish or fail first.
Quick Boot after an unclean shutdown. If the emulator crashed or was force-killed, the snapshot may be corrupted. Cold boot after any abnormal termination.
No HAXM/KVM acceleration. Without hardware acceleration the emulator runs 10-50x slower and often times out ADB connections. Check with emulator -accel-check.
Multiple Android Studio instances. Each can start its own ADB server, and two competing servers make both report emulators as offline. Close the other instances or make them share the same ADB binary.
Antivirus quarantining ADB. Some antivirus programs flag adb.exe and block its network access. Add the SDK platform-tools directory to the exclusion list.
Related reading
- Android emulator doesn't take keyboard input - SDK tools rev 20
- Android Emulator Error Message PANIC Missing emulator engine program for 'x86' CPUS.
- Android Emulator Installation error INSTALL_FAILED_VERSION_DOWNGRADE
- Android Emulator issues in new versions - The emulator process has terminated
- Android emulator not able to access the internet
- Android error Failed to install .apk on device timeout
- Android Endless List
- Android equivalent of NSUserDefaults in iOS
.png&w=3840&q=75)
Tackling System Design Interview Problems
A short course that equips you with the skills to approach system design interviews methodically.
Start the free courseNo course covers this one yet
Basis Lab writes one for you from a sentence about what you want to be able to do, then teaches it and checks you understood. Your first course is free.
Build my courseData Structures & Algorithms practice on Codemia
Step through 300+ coding interview problems with animated visualisers that show the data structure changing as the code runs. The Blind 75 are free.