adb-shell
A Python implementation of ADB with shell and FileSync functionality.
What it is and what it does
adb-shell is a pure-Python implementation of the Android Debug Bridge protocol, allowing you to connect to and control Android devices programmatically from Python code. It supports both TCP connections (over network) and USB connections, and implements both the shell command interface and the FileSync protocol for file transfer. The package originated from Google's python-adb project and provides authentication via RSA keys.
The library is used primarily for automation, testing, and device management workflows where you need to execute shell commands on Android devices or transfer files without relying on the official ADB command-line tool. It has no runtime dependencies in its base form, though optional async and USB support can be added via extras. The project is dormant but stable, with no known security vulnerabilities.
Use it for:
- Automate Android device testing by executing shell commands and capturing output programmatically
- Build device management tools that control multiple Android devices over a network
- Transfer files to and from Android devices as part of CI/CD or deployment pipelines
- Integrate Android device control into Python-based monitoring or orchestration systems
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Implements ADB (Android Debug Bridge) shell and FileSync protocol in Python, enabling programmatic communication with Android devices over TCP or USB.
Yes, with conditions. The package is stable, has no known vulnerabilities, and carries a permissive license. However, it is dormant (last release over a year ago), so install only if you need ADB protocol support in Python and can tolerate lack of active maintenance. High install friction (source-only distribution) is a minor friction point but not a blocker. Suitable for automation and testing workflows where you control the Android ecosystem.
Install
adb-shell on PyPI
pip
pip install adb-shelluv
uv add adb-shellpoetry
poetry add adb-shellInstalling adb-shell
Before you install
High install friction: the package ships as a source distribution with no prebuilt wheels in the standard index. Maintenance is dormant—last release was over a year ago (2023-09-01) and the last commit was 2024-10-29, indicating the project is not actively developed but remains available.
License in practice
Licensed under Apache License 2.0 (permissive), which allows commercial and private use with minimal restrictions, making it safe to adopt from a licensing perspective.
Quickstart
from adb_shell.adb_device import AdbDeviceTcp
from adb_shell.auth.sign_pythonrsa import PythonRSASigner
device = AdbDeviceTcp('192.168.0.222', 5555)
device.connect(rsa_keys=[signer])
response = device.shell('echo TEST')
Requires RSA key pair for authentication; USB support requires optional installation via pip install adb-shell[usb]; async support requires Python 3.7+ and pip install adb-shell[async].
Verify before relying
- Current compatibility with modern Android versions and ADB protocol revisions
- Whether dormant status affects reliability or security posture in active use
- Actual Python version support despite classifiers listing Python 2 and 3
Package facts
| License | not declared (permissive) |
| Python support | not specified |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | dormant — 1,078 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 128,383/month — #11,712 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: adb_shell-0.4.4.tar.gz
Keywords: adb, android
Tags
More Networking packages
h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
psutilpsutil retrieves real-time information about…
permissive · top 1,000 on PyPI
pyOpenSSLpyOpenSSL wraps OpenSSL's SSL/TLS functionality…
permissive · top 1,000 on PyPI
uvloopuvloop is a drop-in replacement for Python's…
permissive · top 1,000 on PyPI
execnetexecnet lets you spawn and communicate with…
permissive · top 1,000 on PyPI
pyzmqPyZMQ provides Python bindings for ZeroMQ…
permissive · top 1,000 on PyPI
adbutilsadbutils is a Python library that communicates…
permissive · top 15,000 on PyPI
pure-python-adbPure-Python ADB client that communicates with…
permissive · top 15,000 on PyPI
androidtvremote2A Python library for controlling Android TV…
permissive · top 15,000 on PyPI
uiautomator2Automates Android device interactions from…
permissive · top 15,000 on PyPI
uiautomatorPython wrapper for Android's uiautomator…
permissive · top 15,000 on PyPI
brainstemProvides Python bindings to control and…
unclear · top 15,000 on PyPI
binho-host-adapterControls Binho Multi-Protocol USB Host Adapters…
permissive · top 15,000 on PyPI
alibabacloud-adb20211201Provides a Python client library for…
permissive · top 5,000 on PyPI
pyftdiPyFtdi provides a pure-Python user-space driver…
permissive · top 15,000 on PyPI
aiousbwatcherWatches for USB devices being plugged in and…
permissive · top 15,000 on PyPI