Generated by GPT-5-mini| ADB | |
|---|---|
| Name | ADB |
| Developer | |
| Initial release | 2008 |
| Programming language | C (programming language), Java (programming language) |
| Operating system | Android (operating system), Windows, macOS, Linux |
| License | Apache License |
ADB is a command-line tool used to communicate with devices running Android (operating system), enabling developers, testers, and administrators to perform a wide range of tasks such as application installation, debugging, file transfer, and shell access. It acts as a bridge between a host machine and an Android device or emulator, facilitating interactions with components like the Android Debug Bridge, Android SDK, and device runtimes such as Android Runtime. ADB is commonly bundled with the Android SDK Platform-tools and integrates with tooling from vendors and projects including Android Studio, Gradle, and Eclipse (software).
ADB provides a client–server–daemon architecture that allows a host running Windows, macOS, or Linux to control an Android device or emulator instance such as those created by Android Emulator or Genymotion. Typical workflows interoperate with development environments like Android Studio and build systems like Gradle to install artifacts produced by continuous integration servers such as Jenkins (software), Travis CI, or CircleCI. ADB supports interactions with device processes like zygote and services managed by init (Android), enabling tasks ranging from log inspection with logcat to package management with pm.
ADB originated as part of the Android Open Source Project maintained by Google to provide tooling for Android platform development and debugging. Over time, ADB evolved alongside releases such as Android 1.0, Android 2.3 Gingerbread, Android 4.4 KitKat, Android 5.0 Lollipop, Android 6.0 Marshmallow, Android 7.0 Nougat, Android 8.0 Oreo, Android 9.0 Pie, Android 10, Android 11, and later platform updates, adding features for newer security models and runtime changes like ART (Android Runtime). The toolset integrated with the Android SDK Platform-tools distribution and received contributions from both Google engineers and downstream projects that package SDK components for distributions such as Debian, Ubuntu, Homebrew (package manager), and Chocolatey.
ADB uses a three-part architecture: a host-side client, a background server daemon running on the host, and a device-side daemon that runs on the Android device. Client components are invoked via the adb executable and communicate over TCP/IP or USB using the Android Debug Bridge protocol. Device-side daemons interact with services exposed by adb daemon and system components like init (Android), allowing forwarding of ports, file push/pull through adb sync, and execution of commands via a shell. Emulators created by Android Emulator or virtual devices from Android Virtual Device configurations expose adb endpoints to tools like Android Studio and third-party IDEs such as IntelliJ IDEA and Visual Studio Code.
ADB exposes commands and features used across development, QA, and support workflows: common commands include adb devices, adb connect, adb push, adb pull, adb shell, adb install, adb uninstall, adb logcat, adb forward, adb reverse, adb bugreport, and adb root. These commands interact with platform-level services like Package Manager (Android), Activity Manager (am), and logging facilities such as logcat. Other advanced functions include port forwarding for web debugging with Chrome (web browser), screen recording compatible with Android ScreenRecord, and screenshot capture for integration with automated testing frameworks like Appium, Espresso (Android testing), and Robotium.
ADB is used to install APKs produced by build systems such as Gradle and Maven (software), capture device logs for issues reported in systems like JIRA (software) or Bugzilla, and run shell scripts to reproduce bugs found during QA cycles. It integrates with continuous integration and delivery pipelines orchestrated by Jenkins (software), GitLab CI/CD, or Bamboo (software), and assists device management in enterprise environments using MDM solutions like Microsoft Intune and VMware Workspace ONE. Test automation suites such as Appium and Espresso (Android testing) use ADB to control emulators and physical devices in labs orchestrated by projects like Firebase Test Lab.
ADB requires explicit authorization on devices running newer platform versions: when a host first connects via USB or TCP/IP, the device displays a prompt for the RSA key fingerprint to grant access, aligning with security changes introduced in releases like Android 4.2.2 and later hardened in Android 6.0 Marshmallow. Running certain commands (for example, modifying protected partitions) may require elevated privileges provided by adb root on engineering or rooted builds, while production devices enforce restrictions via SELinux (Android) and verified boot mechanisms such as Android Verified Boot. Device management often involves policies set by vendors or enterprise mobility management offerings like Google Play EMM API.
Related tooling includes platform-level utilities and third-party replacements: Fastboot provides bootloader-level flashing and device unlocking, Sideload (Android) and Recovery mode workflows handle OTA updates, and projects like Scrcpy enable screen mirroring using adb-backed connections. Other developer utilities include Android Debug Bridge (protocol) clients embedded in IDEs such as Android Studio and standalone implementations packaged by distributions like Homebrew (package manager). Mobile device management tools like Kubernetes-adjacent device farms and services such as Firebase Test Lab provide higher-level orchestration that relies on adb for device control.
Category:Android development tools