How MCP servers work in Warp
When an MCP server is running, it registers a set of tools with the agent. The agent sees these tools alongside its built-in tools (run command, read file, etc.) and decides when to call them based on your prompt. Results are returned to the agent as context for its next step. Warp supports two transport types:| Transport | How it works |
|---|---|
| stdio | Warp spawns a local process and communicates over stdin/stdout. Best for servers distributed as npm packages or executables. |
| HTTP (streamable) | Warp connects to a running HTTP server over a URL. Best for remote or OAuth-authenticated servers. |
Adding MCP servers in settings
The simplest way to add an MCP server is through Warp’s settings UI.Add a server
Click Add MCP server. You can paste a JSON snippet for a stdio server, enter an HTTP URL for a remote server, or pick from the MCP gallery.
Configure variables
Some servers require environment variables (API keys, URLs, etc.). Warp will prompt you to fill in any required variables before activating the server.
MCP servers you add in settings are available in all Agent Mode sessions, regardless of which repository you have open. Use file-based MCP configuration (see below) when you want a server scoped to a specific project.
File-based MCP configuration
Warp watches for MCP configuration files in your repository roots and home directory. When it finds one, it activates the servers defined in that file automatically — no settings UI required. This makes it easy to commit MCP configuration alongside your code so every contributor gets the same tools. The file-based MCP feature (FileBasedMcp) must be enabled in your Warp account. When it is, Warp watches the following paths:
| Provider | Home config path | Project config path |
|---|---|---|
| Warp | ~/.warp/.mcp.json | .warp/.mcp.json |
| Claude | ~/.claude.json | .mcp.json |
| Codex | ~/.codex/config.toml | .codex/config.toml |
| Other agents | ~/.agents/.mcp.json | .agents/.mcp.json |
Example .mcp.json
The repository root of the Warp client itself includes an.mcp.json that registers the official GitHub MCP server:
.mcp.json in the root of your repository. Warp will pick it up the next time you open that project.
stdio server format
${VARIABLE_NAME} syntax to forward environment variables from your shell to the server process without hard-coding secrets in the file.
HTTP server format
The MCP gallery
The MCP gallery is a curated list of popular MCP servers you can add to Warp with a single click. Open it from Settings → AI → MCP Servers → Browse gallery. The gallery includes servers for common tools like GitHub, Linear, Slack, Postgres, and browser automation. Each gallery entry includes a description of the tools it provides, installation requirements, and any variables you need to configure.OAuth-authenticated MCP servers
Some MCP servers use OAuth to authenticate with third-party services (for example, a server that calls the GitHub API on your behalf). When theMcpOauth feature is enabled, Warp handles the OAuth flow for you:
- When you add an OAuth MCP server, Warp opens a browser window to the provider’s authorization page.
- You grant the requested permissions.
- Warp stores the resulting token securely and injects it into the MCP connection automatically.
Managing MCP servers with oz mcp
Theoz mcp CLI commands let you list and manage MCP servers without opening the settings UI.
Debugging MCP servers
If a server fails to start or its tools are not appearing, check the MCP server logs:- In the settings UI, click the server name and open the Logs tab.
- From the CLI:
oz mcp logs <server_name>
Next steps
Skills
Package reusable prompt instructions that work alongside MCP tools.
Rules
Define project-level rules to guide how the agent uses its tools.
Agent Mode
Learn how to send prompts and review diffs in Agent Mode.
oz mcp reference
Full CLI reference for the oz mcp command group.