codex-mcp-tool

MCP.Pizza Chef: x51xxx

This MCP server connects your Claude Desktop or Cursor app to the Codex command-line tool, enabling you to analyze code files, have ongoing coding conversations, brainstorm ideas, and safely automate code changes. You can reference files directly, switch AI models, and even run local AI models. Setup requires adding a small config snippet and running a simple command. You need Codex CLI installed and authenticated, but no extra API keys. It works cross-platform on Windows, macOS, and Linux.

Coding
Other
Web/Research

Use This MCP server To

Analyze and explain code files by referencing them directly Continue multi-turn coding conversations with session memory Brainstorm software ideas using creative frameworks Run safe code automation with sandbox approval Search the web for up-to-date programming info Switch between AI models including local ones Review and refactor code with structured change output

README

Codex MCP Server

GitHub Release npm version npm downloads License: MIT

MCP server connecting Claude/Cursor to Codex CLI. Enables code analysis via @ file references, multi-turn conversations, sandboxed edits, and structured change mode.

Features

  • File Analysis — Reference files with @src/, @package.json syntax
  • Multi-Turn Sessions — Conversation continuity with workspace isolation
  • Native Resume — Uses codex resume for context preservation (CLI v0.36.0+)
  • Local OSS Models — Run with Ollama or LM Studio via localProvider
  • Web Search — Research capabilities with search: true
  • Sandbox Mode — Safe automation with explicit sandbox and approval policies
  • Change Mode — Structured OLD/NEW patch output for refactoring
  • Brainstorming — SCAMPER, design-thinking, lateral thinking frameworks
  • Health Diagnostics — CLI version, features, and session monitoring
  • Cross-Platform — Windows, macOS, Linux fully supported

Quick Start

claude mcp add codex-cli -- npx -y @trishchuk/codex-mcp-tool

Prerequisites: Node.js 18+, Codex CLI installed and authenticated.

Configuration

{
  "mcpServers": {
    "codex-cli": {
      "command": "npx",
      "args": ["-y", "@trishchuk/codex-mcp-tool"]
    }
  }
}

codex-mcp-tool FAQ

Can I use this to analyze and explain code files in my project?
Yes — you can reference files directly and ask Codex to analyze or explain them within supported apps like Claude Desktop or Cursor.
Can I use this to brainstorm ideas for software development?
Yes — it supports creative brainstorming methods like SCAMPER to generate ideas.
Which apps support this Codex MCP server?
It works with Claude Desktop and Cursor apps that support MCP servers.
Do I need an API key or account to use this?
You need to have Codex CLI installed and authenticated, but no separate API key is required for the MCP server itself.
How hard is it to set up?
Setup involves adding a small config snippet and running an npx command, so it's a copy-paste-config level setup.
Can I use different AI models with this?
Yes — you can specify models like OpenAI's GPT-5.6 series, or local models via Ollama or LM Studio.
Does it keep context between questions?
Yes — it supports multi-turn sessions with workspace isolation for ongoing conversations.
Can it safely run code or scripts?
Yes — it has a sandbox mode requiring explicit approval for automation tasks.