# Onboard Codex to Demofy

[← All agents](https://demofy.io/agent-setup)

One \`codex mcp add\` connects Codex CLI to the Demofy MCP server, reading your API key from an environment variable.

[Onboard your AI agent to Demofy](https://demofy.io/agent-setup)

- [Claude Code](https://demofy.io/agent-setup/claude-code)
- [Codex](https://demofy.io/agent-setup/codex)
- [Cursor](https://demofy.io/agent-setup/cursor)
- [OpenCode](https://demofy.io/agent-setup/opencode)

## Commands

````
Demofy runs an MCP server at https://app.demofy.io/api/mcp. To connect Codex to it:

1. This setup uses an API key, and the key is the user's to make: ask them to create one in Settings, under API keys, and to set it in their own shell as `DEMOFY_API_KEY`. Never ask them to paste the key into a file, and never write it into one yourself. To sign in with OAuth instead, add the same URL with no header and no key, as section 2 says.
2. Once `DEMOFY_API_KEY` is set, run:

```bash
codex mcp add Demofy --url https://app.demofy.io/api/mcp --bearer-token-env-var DEMOFY_API_KEY
```

   Codex stores the variable's name, never the key, and asks the user before it runs the server's
   `execute_typescript`, since a program can change something.
3. Read [https://demofy.io/docs/mcp](https://demofy.io/docs/mcp) before the first call that cannot be undone: shipping an edit, re-rendering, shooting a demo again and deleting one each answer with a `confirmToken` first. Show the user what the call will do, and call again with the token only once they agree.
4. Without a connection there is still the web app: open [https://demofy.io/](https://demofy.io/), paste the URL of the app to film and one sentence about what to show. No account is required for the first demo; signing up at [https://demofy.io/sign-up](https://demofy.io/sign-up) keeps demos across sessions.
5. If they want Demofy in its own window, it installs as an app: open [https://app.demofy.io/apps](https://app.demofy.io/apps) and use the Install button there. Starting a demo from a tab they already have open, in one click, needs the Demofy browser extension: it is installed from its Chrome Web Store page, [https://chromewebstore.google.com/detail/demofy-ai-product-demo-vi/febaihdmkjgejcfagbehmennihehndma](https://chromewebstore.google.com/detail/demofy-ai-product-demo-vi/febaihdmkjgejcfagbehmennihehndma), its Microsoft Edge Add-ons page, [https://microsoftedge.microsoft.com/addons/detail/ahaajokdgngjfoigefcajclgljkilece](https://microsoftedge.microsoft.com/addons/detail/ahaajokdgngjfoigefcajclgljkilece), or its Firefox Add-ons page, [https://addons.mozilla.org/firefox/addon/demofy/](https://addons.mozilla.org/firefox/addon/demofy/) — send the user to the one for their browser, since adding an extension is their click in their own browser; it is listed for Chrome, Edge and Firefox so far. Do not try to build it, and do not clone any repository looking for it.

A guest gets 3 demos a day; a signed-up account gets 10, whichever door the demo comes through.
````

Canonical page: https://demofy.io/agent-setup/codex
