Client Configuration Guide

How to Configure MCP in OpenCode

OpenCode coding agent with local and remote MCP servers configured under the mcp key.

Official OpenCode Docs

macOS

<project>/opencode.json

Windows

<project>\opencode.json

Linux

<project>/opencode.json

Setup and verification

Configuration: opencode.json / mcp / Guide only

Documentation reviewed: 2026-11-02. This is not a runtime test or security audit.

  1. Open the project opencode.json (JSONC is also supported), or global ~/.config/opencode/opencode.json.
  2. Use the documented mcp object. Local servers require type: local, a command array and environment; remote servers use type: remote, url and optional headers.
  3. Enable the server and review authentication and tool permissions in OpenCode.

OpenCode does not use the Claude-style mcpServers schema. No OpenCode-specific generated snippets are published here.

Review every command and requested permission. Merge only the relevant server entries; do not overwrite unrelated settings. Keep credentials out of version control.

Reviewed configurations for OpenCode

0 servers with a documentation-reviewed configuration for at least one platform. Check the platform selector before copying.

No reviewed configurations for this client are published yet. Other clients' server lists are not evidence of compatibility. Use the official setup guide.