Gradle MCP Server

MCP server that resolves external Java/Kotlin classes from Gradle dependencies — returns artifact coordinates and class structure in one call.

Local serverstdio

What is the Gradle MCP Server?

MCP server that resolves external Java/Kotlin classes from Gradle dependencies — returns artifact coordinates and class structure in one call.

What it actually does

A Model Context Protocol (MCP) server that lets AI agents look up external Java/Kotlin classes in a Gradle project in a single tool call — no more chains of find, grep, jar, and javap.

Configuration

  • Node.js 18+ - A JDK on PATH (so javap is available) - The target project must have a Gradle wrapper (./gradlew on macOS/Linux, gradlew.bat on Windows) - macOS, Linux, or Windows

More MCP options

Compare MCP servers by category, or browse hosted MCP servers if you prefer an endpoint over a local process.

Maintainer setup documentation.

Recorded tools

Check the linked publisher documentation and your connected client's tool list. Names and availability can vary with the server version and account permissions.

ToolWhat it does
resolve_external_classResolve and inspect a class from external dependencies when you DON'T know which JAR contains it. Replaces manual find / grep / jar / javap chains.
inspect_classSame class structure as resolve_external_class, but takes a jarPath directly — skips Gradle classpath resolution. Use this when the JAR path is already known (e.g. from a previous resolve_external_class result or list_de
list_dependenciesList all resolved external dependencies across every source set's compile classpath (main + test + custom). Each entry includes sourceSets, e.g. ["main"], ["test"], or ["main","test"].
find_dependency_versionSubstring-match against group / artifact and return resolved versions. Case-insensitive.
dependency_insightWraps ./gradlew dependencyInsight --configuration compileClasspath --dependency <query>. Returns the raw resolution chain and a parsed requestedBy list.
check_outdatedCompares resolved versions against the latest available on Maven Central **and** any other repositories the project declares — whether in a project repositories {} block or centrally in settings.gradle under dependencyRe

How to install the Gradle MCP Server

claude mcp add gradle -- npx -y gradle-mcp-server

Configuration

  • Node.js 18+ - A JDK on PATH (so javap is available) - The target project must have a Gradle wrapper (./gradlew on macOS/Linux, gradlew.bat on Windows) - macOS, Linux, or Windows

Example prompts to try

  • “Use Gradle to resolve external class.”
  • “Use Gradle to inspect class.”
  • “Use Gradle to list dependencies.”

Frequently asked questions

MCP server that resolves external Java/Kotlin classes from Gradle dependencies — returns artifact coordinates and class structure in one call. Confirm the tools offered by your installed version in the connected client. Tool availability and permissions depend on the server and account configuration.