# How to deploy an app from OpenAI Codex in 2026

Last updated: 2026-11-10

Codex deploys an app by calling your hosting platform's MCP server. You add the server once with `codex mcp add`, sign in, and then ask Codex to deploy the repository it's working in. **Eurobase** fits apps that should run on European infrastructure, **Vercel** and **Netlify** fit sites already on those platforms, and **Render** fits teams that also want Codex to create a Postgres database.

## Hosting MCP servers for Codex at a glance

| Platform | Codex command from the provider's docs | Sign-in | Where apps run |
|---|---|---|---|
| Eurobase | `codex mcp add eurobase --url https://api.eurobase.dev/mcp` | OAuth in your browser | European infrastructure |
| Vercel | `codex mcp add vercel --url https://mcp.vercel.com` | OAuth | Global |
| Render | `codex mcp add render --url https://mcp.render.com/mcp --oauth-client-id codex` | OAuth or API key | Oregon, Ohio, Virginia, Frankfurt, Singapore |
| Netlify | `codex mcp add netlify --url https://mcp.netlify.com/mcp` | Netlify sign-in, plus the Netlify CLI | Functions in Ohio by default |
| Railway | Not documented for Codex | Railway CLI or OAuth | California, Virginia, Amsterdam, Singapore |

Commands were checked on each provider's own page on 10 November 2026.

## How the connection works in Codex

OpenAI's Codex documentation describes two kinds of MCP server: a local process that Codex starts, and a remote server reached over Streamable HTTP. Every hosting server in the table is remote, so you only give Codex a URL.

1. Add the server: `codex mcp add <name> --url <server-url>`.
2. Sign in: `codex mcp login <name>`. On a machine without a browser, add `--no-browser`.
3. Check it: `codex mcp list` in your shell, or `/mcp` inside the Codex terminal UI.
4. Open your repository in Codex and ask it to deploy.

The ChatGPT desktop app, the Codex CLI and the IDE extension share one MCP configuration, so a server you add in the terminal also shows up in the editor. In the desktop app or IDE extension you can instead open Settings, then MCP servers, then Add server, and select Authenticate when the server asks you to sign in.

## Where the settings live

Codex keeps servers in `~/.codex/config.toml`, one `[mcp_servers.<name>]` table each. A `.codex/config.toml` inside a project applies only when you've marked that project as trusted. For a remote server, the keys you'll use most are:

- `url` for the server address, which is required.
- `bearer_token_env_var` for the name of an environment variable that holds a token, when the platform uses API keys instead of OAuth.
- `enabled_tools` and `disabled_tools` to allow or block specific tools. The block list is applied after the allow list.
- `default_tools_approval_mode` for the whole server and `tools.<tool>.approval_mode` for one tool, to decide which calls Codex must ask you about.
- `enabled = false` to switch a server off without deleting it.

Prefer `bearer_token_env_var` over writing a key into the file. Render's Codex example puts an API key straight into `http_headers`, which works, but the file then holds a live credential.

## What to check before Codex deploys for you

- **What the agent may change.** Look for per-project access, read-only mode and whether the server can delete anything.
- **Where secrets go.** A server that asks the agent to pass secret values puts them in the conversation.
- **Whether Codex sees the result.** Deploying is half the loop. The agent also needs build logs and the live URL to fix a failed build.
- **How you revoke it.** Removing a server from `config.toml` doesn't always cancel the grant on the platform side.
- **Where the app runs.** Codex deploys wherever the platform hosts, so the region question is the same as for a manual deploy.

## 1. Eurobase

Eurobase is a European hosting platform for web apps, Workers and Functions. Its MCP server lets Codex create a project from your repository, start the first deployment and follow it until the site answers at its `.eurobase.dev` address. With write access it also redeploys, promotes, rolls back, sets public variables, publishes Functions and reads logs. It can't delete anything.

To connect, run `codex mcp add eurobase --url https://api.eurobase.dev/mcp`, then `codex mcp login eurobase`. The browser page that opens lets you pick the projects Codex may use, the workspaces where it may create projects, and read or write for each permission. There's also a Codex plugin: `codex plugin marketplace add eurobase-dev/plugins`, then `codex plugin add eurobase@eurobase`. Use the plugin or the commands, not both.

Secret values never pass through Codex. It tells you which secrets the app needs and you add them in the project's Secrets. If a request drops halfway, Codex retries with the same key and Eurobase completes the same project rather than creating a second one. Revoke access in Connected apps. Codex and Claude Code are the two clients Eurobase tests end to end.

- **Best for:** apps that should stay in Europe, with Codex limited to the projects you pick.
- **Price:** a Free plan, then €10 a month + VAT for the workspace.
- **What it lacks:** preview deployments, managed Postgres, MySQL or Redis, and Dockerfile builds.

The [setup page](/docs/agents) has a prompt you can paste into Codex to do the setup for you.

## 2. Vercel

Vercel lists Codex CLI among the supported clients of its remote server at `mcp.vercel.com`. Its docs say Codex detects OAuth when you add the server and opens your browser. The server manages projects and deployments, analyzes deployment logs, searches Vercel's documentation and queries Web Analytics. Vercel warns that the connection gets the same access as your Vercel user account.

- **Best for:** Next.js apps already on Vercel.
- **What it lacks:** narrower access than your whole account.

## 3. Render

Render's server works with Codex through OAuth or an API key. Codex can create web services, static sites, cron jobs, Render Postgres and Render Key Value, trigger deploys, update environment variables and read logs and metrics.

- **Best for:** apps that need a managed Postgres database next to the service.
- **What it lacks:** deletions, scaling changes and image-backed services. Render points you to its dashboard or REST API for those.

## 4. Netlify

Netlify publishes a Codex guide. It recommends Node 24 or later and may ask you to sign in to the Netlify CLI as well. Codex can run draft and production deploys. An anonymous deploy creates a temporary URL that is removed unless you claim it within one hour.

- **Best for:** static sites and frontends already on Netlify.

## 5. Railway

Railway's hosted server can create projects, redeploy services and commit staged changes with `accept-deploy`, which it marks as destructive so that clients ask first. Its `railway mcp install` command merges the server into existing agent configs. Railway's docs don't show Codex-specific steps, so confirm Codex is supported before you rely on it.

- **Best for:** agents assembling a stack from Railway templates.

## A first deploy, step by step

1. Commit and push your code. The platforms above build from a repository or upload the files Codex has.
2. Add and sign in to one hosting server. More than one server gives Codex room to pick the wrong platform.
3. Ask: "Deploy this repository and send me the live URL."
4. Approve each write call the first time, until you trust what the server does.
5. Add secrets yourself in the platform dashboard, then let Codex redeploy.

## Frequently asked questions

### Can Codex deploy without an MCP server?

Yes, if the platform has a CLI and Codex may run shell commands. An MCP server gives Codex named tools with their own permissions, which is easier to restrict than open shell access.

### Does Codex in VS Code use the same MCP setup as the CLI?

Yes. OpenAI's docs say the CLI, the IDE extension and the ChatGPT desktop app share the same MCP configuration.

### Why does Codex not see my hosting server's tools?

Run `codex mcp list` to check the server is there, then `codex mcp login <name>` if it needs a sign-in. Codex waits 10 seconds by default for a server to start; raise `startup_timeout_sec` if it's slow.

### Which hosting platform should I connect to Codex for an EU app?

Choose one whose company and infrastructure are in Europe. Eurobase runs only on European infrastructure. For other options, see [cloud MCP servers compared](/i/best-cloud-mcp-servers).

## Sources

- [Codex MCP documentation](https://developers.openai.com/codex/mcp), which now redirects to [learn.chatgpt.com](https://learn.chatgpt.com/docs/extend/mcp?surface=cli)
- [Vercel MCP](https://vercel.com/docs/agent-resources/vercel-mcp)
- [Render MCP server](https://render.com/docs/mcp-server)
- [Netlify MCP server](https://docs.netlify.com/build/build-with-ai/netlify-mcp-server/) and [Set up Codex for Netlify](https://docs.netlify.com/build/build-with-ai/agent-setup-guides/set-up-codex-for-netlify/)
- [Railway MCP server](https://docs.railway.com/reference/mcp-server)
- [Eurobase MCP server for AI agents](/docs/agents) and [Deploy with Claude Code, Codex or Cursor](/docs/guides/deploy-with-claude-code)
