codex-with-claude
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@codex-with-claudeReview the latest git diff and recorded test results for the current workspace."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Chat to Codex (C2C)
English | Bahasa Indonesia | 简体中文
Bring your AI chat sessions to Codex. Claude Web, ChatGPT, or any chat that speaks remote MCP plans, reasons, and reviews — Codex executes, connected through a secure, read-only MCP bridge.
No Claude API key. No reverse proxy. Claude connects to an OAuth-protected remote MCP endpoint and reads only the workspace data it needs.
One connector, many projects. Connect Claude once. Adding, switching, or closing projects requires no new connector, OAuth flow, or pairing.
Read-only by construction. Claude gets no write, shell, commit, or execution tools. Codex remains the sole executor and mutator.
Workspace-isolated. Projects are registered locally. Claude sees opaque workspace IDs, not arbitrary filesystem roots, and every file operation is confined to the granted workspace.
Local-first. Your source code stays on your machine and is exposed only through explicit, read-only MCP requests.
Based on codex-with-chatgpt.
Multiple chat brains
One installation serves several AI chats at once. Connect Claude Web,
ChatGPT (Plus — Developer mode → Connectors → Create → paste the /mcp
URL → OAuth → pairing code), or both: each holds its own token against
the installation and reads the same registered workspaces. None of them
can write, execute, or commit — Codex stays the only hands.
Related MCP server: Claude Code MCP Bridge
How it works
Claude Web (plan · reason · review)
│
│ OAuth once · one connector
▼
C2C Broker ─────── stable /mcp endpoint
│
│ opaque workspace capabilities
│
├── Project A ◄── Codex session
├── Project B ◄── Codex session
└── Project C
▲
│ edit · shell · git · tests
│
Codex (execute · repair)Claude inspects code, diffs, git state, and recorded test results through the broker, then gives Codex a plan. Codex is the only component that changes anything.
Every Claude-facing capability is read-only. Workspaces are registered locally by Codex/C2C and addressed through opaque IDs. Filesystem paths are canonicalized and confined to the granted workspace, while sensitive files such as .env, private keys, and credentials are denied.
Quick start
Requirements: Node.js ≥ 20, git, cloudflared, and Claude Web with custom connector support.
git clone https://github.com/willio/chat-to-codex.git
cd chat-to-codex
pnpm install
pnpm build
node bin/c2c.js install # systemwide install: ~/.c2c (app + state + launcher)Install the Codex skill:
mkdir -p ~/.codex/skills/chat-to-codex
cp skill/SKILL.md ~/.codex/skills/chat-to-codex/Connect Claude — once
From your first project:
cd ~/Projects/your-project
c2c setup --mode quickOn first run, choose how the public endpoint is exposed:
c2c setup --mode quick— temporary Quick Tunnel (no account)c2c setup --mode named --zone example.com— stable hostname (Cloudflare)
C2C starts the broker and gives you the MCP endpoint and a one-time pairing code when authorization is still needed.
In Claude Web:
Customize → Connectors → Add custom connector
Paste the /mcp URL, complete OAuth, and enter the pairing code.
Pairing codes expire after approximately five minutes. If necessary, generate another while the authorization page is open:
c2c pairThat's the only Claude-side setup.
Connect ChatGPT — optional second brain
ChatGPT Plus shares the same broker: both brains read the same registered workspaces, each with its own token. (Free ChatGPT has no custom connectors.)
Manage connectors on chatgpt.com in a browser — the macOS app hides the settings.
Enable Developer mode: Settings → Connectors → scroll to Advanced settings → toggle Developer mode (beta).
On the Plugins page, the + button opens the New Plugin dialog:
Name:
Chat to CodexConnection: keep Server URL selected and enter the same
/mcpURL from setup (Streamable HTTP — no/ssesuffix needed)Authentication: OAuth — leave the Advanced OAuth settings client ID empty; ChatGPT registers itself dynamically
Tick the risk acknowledgment → Create
ChatGPT shows Authenticate → the C2C authorization page opens → run
c2c broker pairand enter the fresh code.Keep the ChatGPT tab in the foreground until it finishes connecting — backgrounded tabs throttle the token exchange and the connection stalls.
Enable the connector via the + menu and ask ChatGPT to call
list_workspaces.
Add another project
cd ~/Projects/another-project
codexThe Codex skill registers the workspace with the existing C2C installation. No new Claude connector, OAuth authorization, or pairing is required.
For a permanent connector URL, use a named Cloudflare tunnel:
c2c broker tunnel choose --mode named --zone <domain>A stable endpoint is recommended for the single connector you keep in Claude. Quick Tunnels remain useful for development and temporary testing.
Advanced: failover profiles. --profile <name> runs an isolated installation (own state, identity, connector) under ~/.c2c/profiles/<name>/ — e.g. a second Claude account on c2c --profile backup broker start --tunnel.
The loop
INIT → PLAN → EXECUTED → REVIEW → DONEClaude retrieves the context it needs through MCP rather than requiring files and diffs to be pasted into the conversation.
Codex executes the plan and records the result:
c2c record --task <id> --iteration <n> --tests "27 passed"Claude can then independently inspect the resulting diff, git state, and recorded outcome before concluding the task.
MCP tools
All tools are read-only:
list_workspaces
workspace_info
list_directory
read_file
search_workspace
git_status
git_diff
test_status
execution_summarytest_status and execution_summary only read results previously recorded by Codex. They cannot run commands or tests.
Security model
No mutation surface. The MCP server exposes no file-write, shell, execution, commit, or other mutation tools. Codex retains exclusive execution authority.
Installation-level authorization. Claude authorizes one C2C installation rather than individual projects. OAuth uses Dynamic Client Registration, PKCE with S256, short-lived pairing codes, refresh-token rotation, and revocation.
Workspace capabilities. Claude can address only workspaces registered locally with C2C. Unknown, missing, or revoked workspace IDs fail closed. Path traversal and symlink escapes are rejected through canonical-path containment.
No arbitrary filesystem roots. Claude works with opaque workspace identities. It cannot nominate another directory on the machine and turn it into a workspace.
Untrusted repository content. Source files, documentation, issues, and other workspace content are treated as data, never as authorization.
Short-lived pairing. Pairing establishes authorization without exposing a long-lived credential in the browser.
See docs/security.md for the threat model and SECURITY.md for vulnerability reporting, docs/multi-workspace.md for the workspace architecture, and docs/local-e2e.md for end-to-end validation.
CLI
c2c setup
c2c use
c2c broker start
c2c broker status
c2c broker pair
c2c doctor
c2c pair
c2c unpair
c2c record
c2c start
c2c status
c2c tunnel
c2c session
c2c logs
c2c sandbox-allow
c2c stopEvery command supports --json for tooling.
c2c doctor diagnoses and repairs the local side where possible. If the public endpoint changes and Claude requires the connector to be re-added, it reports the required action explicitly.
For compatibility, doctor --json exposes the canonical connectorRepair field while retaining chatgptRepair as a deprecated alias.
Compatibility
Chat to Codex began from the ideas and architecture of codex-with-chatgpt and has since evolved into an independent implementation.
The current architecture uses one installation-level Claude connector serving multiple locally registered Codex workspaces.
Compatibility with earlier C2C installations is intentionally non-destructive:
Existing per-project bridges remain supported during migration.
Legacy
codex-with-chatgptstate directories can be adopted.Compatibility fields and aliases are removed only through explicit, versioned changes.
See docs/migration.md.
Development
pnpm install
pnpm typecheck
pnpm test
pnpm buildCI runs typecheck, tests, and build on every push.
Key source areas:
src/broker/ installation endpoint and routing
src/mcp/ read-only MCP tools
src/auth/ OAuth 2.1
src/workspaces/ workspace registry and sessions
src/bridge/ per-project bridge compatibility
src/cli/ C2C command-line interface
docs/ architecture, protocol, security and migrationCredits
Chat to Codex builds on the original idea and architecture of codex-with-chatgpt by @XiaoDuoYa.
The project has since diverged into an independent Claude Web implementation, while preserving attribution to the upstream work and its MIT copyright in LICENSE.
Chat to Codex is an unofficial community project and is not affiliated with or endorsed by Anthropic or OpenAI.
License
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
The Cortex MCP server provides read-only access to real-time engineering context from the Cortex developer portal, allowing AI coding assistants to answer natural language questions about your organization's catalog (microservices, libraries, domains, teams, infrastructure), scorecards (engineering standards and best practices), initiatives (goals and deadlines), and Engineering Intelligence metrics. It includes tools for querying documentation, tracking personal entities, and accessing AI-assisted insights across the entire Cortex ecosystem.
Read-only MCP tools for AI agent discovery, structured resources, and NIULAI information.
Read-only MCP access to authorized Vocci sessions, notes, files, and memory search.
Read-only Remote MCP for externally grounded AI agent trust receipts.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceA read-only MCP server for AI coding agents to inspect repositories, audit code quality, route engineering skills, and plan safe issue/PR workflows.1MIT
- FlicenseNot gradedqualityCmaintenanceExposes Claude Code's file editing, command execution, and test running capabilities as composable MCP tools for any MCP-compatible host, enabling code operations via a stateless bridge.
- AlicenseNot gradedqualityAmaintenanceA local MCP server that lets Claude Code and Codex delegate repository exploration and test proposals to a remote LM Studio model, while enforcing security boundaries by keeping all repository access read-only and never applying patches or running commands remotely.161MIT
- FlicenseNot gradedqualityCmaintenanceExposes a secure, path-confined bridge to a local workspace and git remotes, enabling MCP clients to search, read, write, reset files, and perform git operations.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/willio/chat-to-codex'
If you have feedback or need assistance with the MCP directory API, please join our Discord server