Labsco
MCP SERVER

Gopls MCP

by xieyuschen

Type-checker-accurate Go navigation for an agent - interface implementations, call hierarchies and package dependencies, not text matches.

Code Intelligence & Repository Indexing
Summary
Worth it for the semantic questions; grep is still fine for the rest.

The project is unusually honest about where it does and does not help. Its own benchmark over 11 tasks shows it taking 2 to 4 times fewer tool calls than grep-based navigation on semantic work - finding implementations, tracing calls - while for simple same-file lookups plain grep remains just as effective and carries less overhead.

What it is

A fork of gopls that speaks MCP. Because the answers come from Go's own type checker, it resolves interface satisfaction, cross-package identity and shadowed scopes the way the compiler does, rather than the way a regex does.

What you get
  • Every concrete type that satisfies an interface, resolved rather than guessed
  • Call hierarchies traced through the type system
  • Package dependency mapping across the module
  • Symbol identity that holds across packages, and scoping that respects shadowing
  • A routing skill installed alongside the plugin, so the agent knows when to reach for this instead of grep
Requirements

A Go codebase. The easiest install is the plugin route - one marketplace command in Claude Code or Codex, which installs the binary and the routing skill together. Otherwise a shell installer on Linux and macOS or a PowerShell one on Windows, followed by the per-client setup the project documents. It is a community fork, not a Go team product.

Setup effort

One command — curl -sSL https://gopls-mcp.org/install.sh | bash