How do you debug on Android?


  • I want to debug a game I am running on an Android device.


You want to perform Android device debugging in either MonoDevelop or Visual Studio. This could be because of the following:

  • There are objects with script components on them that are missing their script reference.
  • The game hits breakpoints when running in Unity.
  • Your game crashes and does not run on an Android device.


First, you will need to have your Android developer environment setup before you can test your Unity games on the device. This involves downloading and installing the Android SDK with the different Android platforms and adding your physical device to your system. See this document for steps on how to download and add the Android SDK path to Unity.

You can attach the MonoDevelop debugger to an Android device with ADB via TCP/IP. The process is described in our documentation here.

Debugging Unity scripts on an Android device also works through Visual Studio. The only difference will be choosing Attach Unity Debugger in Visual Studio instead of Attach to process in MonoDevelop.

More Information



Was this article helpful?
1 out of 20 found this helpful
Have more questions? Submit a request


  • 2

    I have tryed attaching VS to an Android device according to the documentation, but it doesn't work.

    Edited by 潘海珲
  • 2
    Martijn Plass

    What a bad page. the 'more information' aren't links and "" leads to a 404.

  • 3
    Silvio Jiménez

    Searched "unity 2018 android debug" on the web, this article was the first result and it is in fact useless.

Please sign in to leave a comment.