android-source-explorer-mcp
by mrmike·★ 91·Score 49
An MCP server providing direct access to Android source code for AI-assisted development.
Overview
The Android Source Explorer MCP server enables AI tools to access current Android source code in real-time, addressing the common problem of outdated training data. It uses a hybrid architecture combining Tree-sitter for fast AST parsing and optional LSP features for cross-file navigation. The server maintains a local cache of AOSP and AndroidX sources to ensure instant lookups and offline capabilities.
Try asking AI
After installing, here are 3 things you can ask your AI assistant:
When to choose this
Choose this when developing Android applications and you need precise, up-to-date information directly from the source code rather than potentially outdated documentation.
When NOT to choose this
Avoid if you're not working with Android development or if you need real-time access to the very latest AOSP changes before they're synced locally.
Tools this server exposes
9 tools extracted from the READMEsearch_classesSearch for classes by glob pattern or substring
lookup_classRetrieve the full source code for a specific class
lookup_methodExtract a precise method body + its Javadoc/annotations
list_class_membersList all method and field signatures in a class
get_class_hierarchyGet the inheritance chain (superclass + interfaces)
search_in_sourceSearch for text/regex across the entire source tree
goto_definitionResolve the cross-file definition of a symbol
find_referencesFind all usages of a class/method across the whole tree
get_type_infoGet documentation and type info via hover data
Comparable tools
Installation
Installation
Prerequisites
- uv (Recommended) or Python 3.11+
- Git
Recommended Installation (via uv)
uv tool install git+https://github.com/mrmike/android-source-explorer-mcpInitial Sync
# Sync API 36 (Android 16) and common AndroidX packages
android-source-explorer sync --api-level 36 --androidx "compose,lifecycle,activity"Configuration
{
"mcpServers": {
"android-sources": {
"command": "android-source-explorer",
"args": ["serve"]
}
}
}Compare android-source-explorer-mcp with
Last updated · Auto-generated from public README + GitHub signals.