Failed to install Android.apk on device

Android Emulator Timeout Error

If you are getting the above error message in the Android ADT Eclipse console when you are trying to run your Android Project either on the emulator or the device, then it's because the APK file is not being uploaded on the device and a timeout has occurred! This is the most common error encountered while working with ADT.

Solution:

  1. Go to your project folder,
  2. Delete the gen folder
  3. Refresh the project
  4. Delete the contents in the bin folder
  5. Now do a Clean + Build
  6. Try to run the App, it should get uploaded

If the above solution does not work for you, then you must try to change the default ADB connection timeout value, i.e., 5000ms to some higher value. Let's see how we can do that:

  1. Go to Menu: Window (on Windows OS, else Eclipse -> Preferences... if on macOS)
  2. Select Android
  3. Under Android, select DDMS
  4. Now look for the text field: ADB connection timeout (ms): change the value from default 5000 to say 15000.
  5. Click on Apply and OK.
  6. Now try to run the Application, it should work without throwing any console errors!

If none of the above works for you, then try to reboot your device, or if on the emulator, close it and re-launch. You can also try to kill the ADB services under Task Manager (Activity Monitor if on Mac OS X) and try.

Android Emulator Timeout Error
Android Emulator Timeout Error

Note: Sometimes faulty USB cords also cause such issues! Try with some other USB cables. Sometimes we have multiple USB ports on the computer (some are USB2 and some USB3), so just try switching ports too!


This is not an AI-generated article but is demonstrated by a human.

Please support independent contributors like Code2care by donating a coffee.

Buy me a coffee!

Buy Code2care a Coffee!

Comments & Discussion

Facing issues? Have questions? Post them here! We're happy to help!