Skip to content

Free ADB command builder ​

In short: The ADB command builder writes adb commands for you. Choose a task, such as installing an APK, reading the log or pairing over Wi-Fi, fill in the details, and pick one phone, a phone by serial number or every connected phone, in bash or PowerShell. Copy the result into your terminal; nothing leaves your browser.

Which phone?
Your shell
Command
adb install -r app.apk
  • The APK is copied from your computer and installed; "Success" means it worked.
  • INSTALL_FAILED_UPDATE_INCOMPATIBLE means the installed app is signed with another key: uninstall it first.

How it works, flags and errors: adb install.

Running the same commands on a whole shelf of phones? BenchFleet shows every connected phone on one screen, with one-click control and, on Pro, group actions that install apps, launch them, reboot phones or take screenshots on many phones at once. See controlling many Android phones from one PC.

Free for up to 3 phones, with no account. Pro adds workflows, schedules and AI for up to 25 phones from £12 a month + VAT.

ADB cheat sheet ​

The commands people use most, with a guide to each.

Connection ​

CommandWhat it doesGuide
adb devices -lLists connected phones, their serial numbers and modelsadb devices
adb -s R58M12345 shellSends a command to one phone when several are connectedADB commands
adb kill-serverStops the ADB server; the next command starts a fresh oneadb devices
adb pair 192.168.1.20:37099Pairs a phone over Wi-Fi (Android 11 and newer)ADB over Wi-Fi
adb connect 192.168.1.20:41037Connects to a paired phone over Wi-FiADB over Wi-Fi
adb tcpip 5555Turns on network adb by USB, on Android 10 and olderADB over Wi-Fi

Apps ​

CommandWhat it doesGuide
adb install -r app.apkInstalls or updates an app, keeping its dataadb install
adb install-multiple base.apk split.apkInstalls an app's split APKs togetheradb install
adb uninstall com.example.appRemoves an appadb uninstall
adb shell pm list packages -3Lists the apps you installedadb uninstall
adb shell pm clear com.example.appClears an app's dataadb shell
adb shell am force-stop com.example.appStops an app at onceadb shell
adb shell monkey -p com.example.app -c android.intent.category.LAUNCHER 1Opens an app by its package nameadb shell
adb shell pm grant com.example.app android.permission.CAMERAGrants a permissionadb shell

Screen and input ​

CommandWhat it doesGuide
adb exec-out screencap -p > screen.pngSaves a screenshot on your computer (bash)adb screenshot
adb shell screenrecord /sdcard/demo.mp4Records the screen, up to 180 secondsadb screenshot
adb shell input text hello%sworldTypes text; %s is a spaceadb shell
adb shell input tap 540 1200Taps a point on the screenadb shell
adb shell input keyevent KEYCODE_HOMEPresses Home; KEYCODE_BACK is Backadb shell
adb shell am start -a android.intent.action.VIEW -d https://example.comOpens a web addressadb shell

Logs and files ​

CommandWhat it doesGuide
adb logcatFollows the log liveadb logcat
adb logcat -d > log.txtSaves the log so far to a file (bash)adb logcat
adb logcat -cClears the logadb logcat
adb logcat -b crash -dShows recent crashesadb logcat
adb bugreport report.zipCollects logs and much more in one fileadb logcat
adb push report.pdf /sdcard/Download/Copies a file to the phoneadb push and pull
adb pull /sdcard/DCIM/CameraCopies the camera's photos to your computeradb push and pull

The phone ​

CommandWhat it doesGuide
adb shell getprop ro.build.version.releaseShows the Android versionadb shell
adb shell dumpsys batteryShows the battery's level and temperatureadb shell
adb shell wm sizeShows the screen's size in pixelsadb shell
adb rebootRestarts the phone; adb reboot recovery restarts into recoveryADB commands

How the builder writes commands ​

  • Quoting for two shells. Anything after adb shell is read by your computer's shell and then by the phone's, so the builder quotes it for both. Web addresses with & and text with apostrophes come through intact.
  • Every phone in turn. For "every connected phone" it loops over the phones that adb devices lists as ready, skipping unauthorized and offline ones, and names saved files after each phone.
  • Windows PowerShell. Windows PowerShell 5.1 changes binary output sent to a file, so screenshots are saved on the phone and copied over instead, and logs are written as UTF-8.
  • Nothing leaves the page. The builder runs in your browser; it sends and stores nothing.

New to adb? Start with ADB commands and the Android Debug Bridge, or see the other ways to control an Android phone from a PC.

Questions ​

Is the ADB command builder free?

Yes, with no sign-up and no limits. It is a page on this site that writes commands; you run them yourself in your terminal with Google's adb.

Does it send my commands or file names anywhere?

No. The builder runs in your browser, sends nothing and stores nothing, so the package names, paths and addresses you type stay on your computer.

Which shells does it support?

bash and zsh, as on macOS, Linux and Git Bash on Windows, and PowerShell on Windows. The commands differ where the shells do, for example in quoting and in saving screenshots.

How does it run a command on every phone?

It writes a loop over the phones that adb devices lists as ready and sends the command to each in turn with -s and its serial number, saving files under each phone's name.

Does it work with emulators?

Yes. Emulators appear in adb devices with serial numbers such as emulator-5554, and every command works on them as on phones.

Start with the Free plan

Free for up to 3 phones, with no account. Pro adds workflows, schedules and AI for up to 25 phones from £12 a month + VAT.