android-sqlite-inspector
v1.0.0
Published
MCP server for inspecting and querying Android SQLite databases via ADB
Downloads
20
Maintainers
Readme
Android SQLite Inspector
MCP server that inspects and queries SQLite databases on Android devices via ADB.
Prerequisites
- Node.js 18+
- ADB installed and in PATH
- A debuggable Android app (debug builds)
Installation
npm install
npm run buildConfiguration
Set via environment variables:
| Variable | Description | Default |
|----------|-------------|---------|
| ANDROID_PACKAGE | App package name | com.hortusys |
| ANDROID_DEVICE | ADB device serial (for multiple devices) | (auto-detect) |
| ADB_PATH | Custom path to ADB binary | adb |
Claude Code Setup
Add to ~/.claude/settings.json:
{
"mcpServers": {
"android-sqlite-inspector": {
"command": "node",
"args": ["/Users/andromeda/StudioProjects/android-sqlite-inspector/dist/index.js"],
"env": {
"ANDROID_PACKAGE": "com.hortusys"
}
}
}
}Available Tools
| Tool | Description |
|------|-------------|
| list_databases | List all .db files in the app's databases directory |
| list_tables | List all tables in a database |
| describe_table | Show column schema for a table |
| query | Execute a SELECT query (returns JSON) |
| execute | Execute INSERT/UPDATE/DELETE (pushes changes back to device) |
How It Works
- Each read operation pulls a fresh copy of the database from the device via
adb shell run-as <package> cat databases/<db> - Queries run locally using
better-sqlite3 - Write operations (
execute) pull the db, modify locally, then push back via ADB
