gemini
An MCP server that allows AI assistants to connect with Google Gemini's command-line interface, taking advantage of Gemini's large token capacity to analyze large files and understand codebases.
claude mcp add --transport stdio tuannvm-gemini-mcp-server npx -y @tuannvm/gemini-mcp-server
How to use
Gemini MCP Server exposes a suite of tools that extend Claude-like capabilities with Gemini's large context window. The server makes it possible to analyze entire codebases, perform web searches for grounded results, process images and documents, run shell commands, and brainstorm ideas using structured methodologies — all through MCP commands. Core tools you can invoke include gemini (codebase and file analysis with Gemini’s 1M+ token context), web-search (Google-grounded web inquiries), analyze-media (image, PDF, and screenshot processing), shell (generate and execute shell commands), and brainstorm (creative ideation workflows). Gemini CLI extensions further augment the server by enabling access to Google Workspace apps like Gmail, Drive, Sheets, Docs, and Calendar, among others, via extensions you install and then call through MCP prompts. This setup lets you perform deep analysis, fetch external data, and automate complex workflows from your MCP-enabled environment.
How to install
Prerequisites:
- Node.js (with npm) installed on your machine.
- Access to a terminal/command prompt.
Install steps:
- Install the Gemini MCP Server package globally (uses npx to run without a local install):
npm install -g @tuannvm/gemini-mcp-server
- Run or call via npx when starting the MCP server in your environment:
npx -y @tuannvm/gemini-mcp-server
Alternatively, you can use it directly in a workflow without a global install by invoking:
npx -y @tuannvm/gemini-mcp-server
- If you follow the VS Code one-click or Claude CLI setup in the README, ensure you configure your MCP to point to the above command/args pair. Example in MCP config:
{ "mcpServers": { "gemini": { "command": "npx", "args": ["-y", "@tuannvm/gemini-mcp-server"] } } }
Prerequisites recap:
- Node.js and npm installed
- Internet access for npm/pnpm/yarn as needed
- Optional: Gemini CLI extensions if you plan to use Google Workspace integrations
Additional notes
Tips and common notes:
- GEMINI_MODEL environment variable can be set to prefer a specific Gemini model (e.g., export GEMINI_MODEL="gemini-3-pro-preview").
- The Gemini CLI extensions enable Gmail, Drive, Sheets, Docs, Calendar, and more; install extensions with gemini extensions install <URL> and use them with yolo=true to auto-approve actions.
- If you encounter authentication prompts when using Gemini CLI, you’ll need to complete the login flow in your environment as described in the Gemini CLI docs.
- The MCP server supports multiple tools (gemini, web-search, analyze-media, shell, brainstorm). You can mix and match within a single MCP session to build end-to-end workflows.
- When running in CI or restricted networks, ensure outbound access to npm registries and Gemini endpoints is allowed.
Related MCP Servers
iterm
A Model Context Protocol server that executes commands in the current iTerm session - useful for REPL and CLI assistance
mcp
Octopus Deploy Official MCP Server
furi
CLI & API for MCP management
editor
MCP Server for Phaser Editor
DoorDash
MCP server from JordanDalton/DoorDash-MCP-Server
mcp
MCP сервер для автоматического создания и развертывания приложений в Timeweb Cloud