Skip to main content
Glama
android-sqlite-inspector

android-sqlite-inspector

by hortusys

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)

Related MCP server: mcp-sqlite-manager

Installation

npm install
npm run build

Configuration

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

  1. Each read operation pulls a fresh copy of the database from the device via adb shell run-as <package> cat databases/<db>

  2. Queries run locally using better-sqlite3

  3. Write operations (execute) pull the db, modify locally, then push back via ADB

Available Tools

12 tools
describe_tableDescribe TableA

Show the schema (columns, types, constraints) for a specific table.

Inputs: table (required), database (required).

executeExecute SQLA

Execute an INSERT, UPDATE, or DELETE SQL statement. Pulls the database, modifies it locally, then pushes it back to the device.

Inputs: sql (required), database (required).

exportExport Query ResultsA

Execute a SELECT query and export results to a local file as JSON or CSV.

Inputs: sql (required), format (required), database (required), file_path (required).

list_databasesList DatabasesA

List all SQLite database files for the Android app (com.hortusys)

Inputs: no named parameters.

list_devicesList Connected DevicesA

List all Android devices/emulators connected via ADB.

Inputs: no named parameters.

list_packagesList Installed PackagesA

List third-party packages installed on the device. Useful for finding the correct package name.

Inputs: no named parameters.

list_tablesList TablesA

List all tables in a SQLite database. Pulls a fresh copy from the device.

Inputs: database (required).

multi_queryMulti QueryA

Execute multiple read-only SQL SELECT queries in a single call. More efficient than calling query multiple times.

Inputs: queries (required), database (required).

queryQuery DatabaseA

Execute a read-only SQL SELECT query. Returns results as JSON. Pulls a fresh copy from the device before querying.

Inputs: sql (required), database (required).

query_paginatedQuery with PaginationA

Execute a SELECT query with LIMIT/OFFSET pagination. Returns results plus total row count.

Inputs: sql (required), limit (required), database (required), offset.

room_infoRoom Database InfoA

Show Room database metadata: schema version, identity hash, and managed entities.

Inputs: database (required).

schema_diffSchema DiffA

Compare schemas of two databases. Shows added/removed tables and columns.

Inputs: database_new (required), database_old (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

    TDQS

    A4/5.0

    Scored across 12 tools

    Disambiguation4/5

    Most tools target distinct actions and resources, but the query variants (query, multi_query, query_paginated, export) overlap in purpose and could be confused if descriptions are not read carefully. The read-only vs. write distinction between query and execute is clear, and schema_diff/room_info are well-separated from the rest.

    Naming Consistency4/5

    The list_* tools follow a clear, consistent pattern, and describe_table, schema_diff, and export are also descriptive. However, room_info breaks the verb-noun pattern, and the query variants mix styles (query, multi_query, query_paginated) though they remain readable.

    Tool Count5/5

    Twelve tools is well-scoped for an Android SQLite inspector, covering discovery, schema inspection, querying, and modification without unnecessary bloat. Each tool has a meaningful role in the workflow.

    Completeness5/5

    The tool surface covers the full inspection lifecycle: device discovery, package/database/table enumeration, schema details, read/write operations, pagination, batch queries, Room metadata, schema diffing, and export. No obvious dead ends or critical missing operations are apparent for the stated purpose.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      Not graded
      maintenance
      Enables comprehensive SQLite database management through natural language, including database creation, table operations, data CRUD operations, backup/restore functionality, and CSV import/export capabilities.
      MIT
    • F
      license
      B
      quality
      D
      maintenance
      Provides comprehensive Android device management capabilities through ADB, including device management, app management, file operations, and system monitoring.
      18
      1
      -