What it does
This MCP server integrates Google Gemini CLI with Claude Code, exposing two main tools: ask-gemini for querying Gemini's analysis capabilities and sandbox-test for safely executing code in an isolated environment. By bridging Claude's reasoning with Gemini's larger token window and search capabilities, it lets you offload expensive analysis tasks—code review of large repositories, dataset parsing, large-file summarization—without exhausting Claude's context limits.
Who it's for
Backend engineers and full-stack developers analyzing large codebases or datasets, and anyone using Claude Code who regularly hits context limits on large files. Useful when you need Gemini's search or extended analysis window but want to stay in Claude Code's interface.
Common use cases
- Analyze a large codebase using Gemini, then iterate on findings with Claude
- Safely test experimental code or scripts in Gemini's sandbox before running locally
- Use Gemini's web search to research libraries, advisories, or best practices within Claude Code
- Break up large-file analysis: send raw content to Gemini for summaries, refine details with Claude
- Parse and explain complex configuration files or data schemas
Setup pitfalls
- Requires Node.js v16+ and Google Gemini CLI installed and configured locally; Gemini CLI setup and API key configuration are prerequisites
- Must ensure Gemini CLI is in PATH and properly authenticated, or the MCP server cannot invoke it
- Reads and writes files on your system; sandbox mode can execute arbitrary code—vet Gemini's responses before running them
- File references use
@syntax matching Gemini CLI conventions; relative paths resolve from the directory where the MCP server runs