Conversion guide

Claude MCP config
to Codex TOML.

Move the same MCP servers from Claude Desktop or Claude Code into OpenAI Codex without rewriting tables, environment variables and HTTP headers by hand.

Convert Claude JSON to Codex

Claude uses an mcpServers JSON object. Codex reads TOML tables under [mcp_servers.<name>]. MCP Config Lab translates the structure, including stdio commands, arguments, environment variables, remote URLs and bearer-token references.

{
  "mcpServers": {
    "docs": {
      "url": "https://example.com/mcp",
      "headers": {
        "Authorization": "Bearer ${MCP_TOKEN}"
      }
    }
  }
}

Becomes:

[mcp_servers.docs]
url = "https://example.com/mcp"
bearer_token_env_var = "MCP_TOKEN"
Convert Claude to Codex →

Where does the Codex MCP config go?

Use ~/.codex/config.toml for user-wide servers or .codex/config.toml inside a trusted project for project-specific configuration. Restart or reload the client after changing its configuration.

What the converter preserves

Before you copy

Review every command in an MCP config before running it. Avoid committing real API keys, access tokens or passwords. The built-in validator flags common credential patterns and insecure remote URLs.