Next-Gen App & Browser
Testing Cloud

Trusted by 2 Mn+ QAs & Devs to accelerate their release cycles

Next-Gen App & Browser Testing Cloud

How to Use Adb (Android Debug Bridge)?

The Android Debug Bridge (ADB) is a command line utility that allows you to communicate with an Android device to debug or update/modify and control it. Below are its primary uses explained in depth:

1. App Installation & Management

ADB allows you to install, uninstall, or manage apps without using the Play Store. You can sideload APKs, remove bloatware, or back up apps. For example:

  • adb install app.apk → Installs an APK file.
  • adb uninstall com.package.name → Removes an app completely.
  • adb shell pm list packages → Lists all installed apps.

2. File Transfer Between PC & Device

You can push (upload) or pull (download) files between your computer and Android device. This is useful for transferring media, backups, or system files.

  • adb push file.txt /sdcard/ → Uploads a file to the device.
  • adb pull /sdcard/file.txt ~/Downloads/ → Downloads a file from the device.

3. Debugging & Logs

ADB helps developers monitor system logs and debug apps in real time.

  • adb logcat → Displays live system logs.
  • adb bugreport → Generates a detailed bug report.
  • adb shell dumpsys → Checks battery, memory, and app performance.

4. Device Control & Automation

You can control your device remotely, automate tasks, or execute shell commands.

  • adb reboot → Restarts the device.
  • adb shell input tap 500 500 → Simulates a screen tap.
  • adb shell am start -n com.android.settings/.Settings → Opens Settings programmatically.

5. Screen Recording & Screenshots

ADB can capture screenshots or record the screen without needing a third-party app.

  • adb shell screencap -p /sdcard/screen.png → Takes a screenshot.
  • adb shell screenrecord /sdcard/video.mp4 → Records screen (stop with Ctrl+C).

6. Wireless Debugging (No USB Needed)

ADB can work over Wi-Fi, eliminating the need for a USB cable.

  • adb tcpip 5555 → Enables TCP/IP mode.
  • adb connect 192.168.x.x → Connects wirelessly via IP.

7. Advanced Modifications (Root Required)

For rooted devices, ADB can modify system files, change permissions, or flash custom ROMs.

  • adb root → Grants root access (if supported).
  • adb remount → Makes system partition writable.
  • adb shell "echo 'test' > /system/file.txt" → Edits system files.

8. Backup & Restore Data

You can back up apps, settings, or entire storage using ADB.

  • adb backup -apk -shared -all -f backup.ab → Creates a full backup..
  • adb restore backup.ab → Restores data from backup.

9. Fastboot & Bootloader Commands

ADB works with Fastboot to unlock bootloaders, flash firmware, or recover bricked devices.

  • adb reboot bootloader → Switches to Fastboot mode.
  • fastboot flashing unlock → Unlocks the bootloader (varies by device).

Test Your Website on 3000+ Browsers

Get 100 minutes of automation test minutes FREE!!

Test Now...

KaneAI - Testing Assistant

World’s first AI-Native E2E testing agent.

...
ShadowLT Logo

Start your journey with LambdaTest

Get 100 minutes of automation test minutes FREE!!

Signup for free