• Skip to main content
  • Skip to primary sidebar

AutomationTestingHub

Selenium, Appium, Cucumber and more !!!

Enable USB Debugging on Android Phone

April 18, 2017 by anish Leave a Comment

Appium is not just limited to opening your app and performing some actions on it. It provides many more functionalities in the way you interact with your app. One such feature is that you can use Appium to install the app on your mobile phone using its .apk file. To use this feature, it would be necessary to enable USB Debugging on your device.

The primary function of USB debugging is to facilitate a connection between an android device and a computer. Developers can use this mode to transfer the app to mobile devices for testing. Enabling USB debugging will provide you with the capability to directly install these apps without going to the app store.

Enabling USB Debugging on your android device is a two step process:
1: Firstly, get the Developer options on your phone
2: Then, use Developer options to enable USB Debugging

Lets look at each of these steps in more detail.

Get the Developer Options on your phone

Why do you need access to “Developer options” on your device? Well, it is considered to be a security feature and hence it is by default a hidden option on your device settings. As the name rightly suggests it is beneficial and mostly used by the developers. Developers use this Mode to transfer apps to a device for testing.

The process to activate Developer Options on an android device is given below:

Step 1: Take your Android device -> go to Menu/Home -> search for the Icon named “Settings”

settings icon on home or menu screen

Step 2: Click on the “Settings” Icon and scroll down through the list.
Under the sub-title “SYSTEM” check for an option named “Developer options”. If you can see “Developer options” listed there, it means Developer options is already enabled on your Android device.

Developer Options in Settings Screen

If Developer options is already enabled, then you can directly skip over to the next section in this article – “Enable USB Debugging option on your phone”

On the other hand, if you do not find the “Developer options” listed there, then please follow the below procedure to enable it –

Step 3: Click on the “About phone” option listed under the “SYSTEM” section at the end of the list . When you click on the “About phone” option, you can see the list of options as shown in the below image

about phone list options

Step 4: Click the “Build Number” option multiple times, till one of these messages appear –
“You are now 2 steps away from being a developer”
“You are now 1 steps away from being a developer”

Enable Developer mode by successively clicking Build number

After this, click on “Build Number” couple of more times until you finally see the below message –
“You are a Developer now” or “Developer mode has been enabled”.
(To be precise – It is 5 clicks on some devices and 7 clicks on others)

you are now a developer

Step 5: Tap the back button on your device to verify the “Developer options” is listed under the “SYSTEM” settings

developer options listed on Setting screen

So now you can see the “Developer options” enabled on your device. Let us now see how to enable the USB debugging option on your android device.

Enable USB Debugging option on your phone

By default the USB debugging mode is disabled for any brand new device to avoid unintentional modifications on it. But you would need to enable debugging option manually for your Android development/testing process.

So now, lets see how to enable the USB debugging mode by following the steps given below:

Step 1: Go to the “Settings” option of your phone and verify again, if you can see the “Developer options” listed under the “SYSTEM” section as shown below

verifying developer options is enabled under settings

Step 2: Click the “Developer options” and check if “USB Debugging” checkbox is listed under the sub-title “Debugging” as shown below:

Availability of USB debugging option under sub-title debugging of developer options

Step 3: Tick the “USB Debugging” checkbox and click “OK” in the popup message. You can see that “USB Debugging” has been enabled now as shown in the below image:

usb debugging option click ok

enable usb debugging option - checkbox ticked

NOTE:- As a best practice, you can disable USB Debugging when you don’t need them, by unchecking the “USB Debugging” mode under the “Developer options”.


You now have USB Debugging enabled on your android phone and you would be able to use Appium to interact with your phone and install & delete apps through code.

Feel free to contact us using the comments section if you face any issues while implementing the steps given in this article. You are now one more step closer to setting up Appium on your machine. Check out our next article from the Appium Tutorial series which would help you download and setup Eclipse IDE.

Filed Under: Appium

Primary Sidebar

Automation Testing Hub

Tutorials Guide

Write test scripts in BDD format using our Cucumber Selenium Tutorial

Use our Appium Tutorial Series to setup Appium from scratch

Categories

  • Android
  • Appium
  • Cucumber
  • Java
  • Playwright
  • Selenium
  • Tosca

Recent Posts

  • Appium Inspector – Download and Install
  • How to download Chromedriver for Selenium
  • Run Playwright tests on different browsers
  • Playwright Automation Testing Tutorial
  • Selenium IDE Chrome Download

Recent Comments

  • Run Playwright tests on different browsers - AutomationTestingHub on Playwright Automation Testing Tutorial
  • Confluence: CPSSoft Test Framework on Appium Inspector – Download and Install
  • Playwright Automation Testing Tutorial - AutomationTestingHub on Download and Install – Node.js and NPM
  • Chrome浏览器在使用Java的Appium中无法启动。 | JAVA语言的经验与见解 on 2 Ways to find appPackage and appActivity name of your App
  • Appium Inspector Tutorial - AutomationTestingHub on Download and Install Appium 2 Server

Archives

  • January 2024
  • July 2023
  • March 2023
  • February 2023
  • May 2018
  • April 2018
  • March 2018
  • February 2018
  • January 2018
  • November 2017
  • October 2017
  • September 2017
  • August 2017
  • July 2017
  • June 2017
  • May 2017
  • April 2017
  • March 2017
  • November 2016
  • October 2016
  • September 2016
  • August 2016
  • July 2016
  • June 2016

Latest Selenium 3 Guide

Are you using the latest version of Selenium WebDriver? It provides lot better support for the latest browser versions. Check it out here - Setup Latest Selenium WebDriver

Categories

  • Android
  • Appium
  • Cucumber
  • Java
  • Playwright
  • Selenium
  • Tosca

Copyright © 2025 · Genesis Sample on Genesis Framework · WordPress · Log in

Go to mobile version