Codex is OpenAI's autonomous coding agent. It takes a task, works in a sandbox, and comes back with a pull request. Here's how to set it up.
What you need
- • A ChatGPT Pro or Team account
- • A GitHub account with repos you want Codex to work on.
Access Codex
Codex lives inside ChatGPT at chatgpt.com/codex. You need a Pro or Team plan. It's not a chatbot, it's an agent that works autonomously on coding tasks.
Think of Codex as a junior developer. Give it a clear task, it goes away, does the work in a sandboxed environment, and comes back with results.
Connect your GitHub repos
Codex needs access to your code. Connect your GitHub account and select which repos it can access.
Start with one repo. You can always add more later. Codex reads your codebase to understand context before making changes.
Write a good task
Codex works best with clear, specific tasks. "Fix the login bug on line 42 of auth.ts" beats "make the app better." Include the file, the problem, and what success looks like.
Our guides come with pre-written Codex tasks. Copy-paste them and Codex knows exactly what to do.
Set up AGENTS.md
AGENTS.md is a file in your repo root that tells Codex how your project works: how to build, test, lint, and what conventions to follow. It's like project instructions for the agent.
Our guides include AGENTS.md templates. Drop it in your repo root and Codex will follow your project's rules.
Review the output
Codex shows you a diff of everything it changed. Review it, ask for modifications, or approve it. Nothing ships until you say so.
Always review the diff. Codex is good but not infallible. Check edge cases and test coverage.
Create a pull request
Once you approve, Codex can open a PR directly on GitHub. Review, merge, done.
Set up branch protection rules so Codex PRs still go through your normal review process.
Go Deeper
Plan First. There Is No Execute Mode.
Plan is how Codex thinks. Auto is what it is allowed to touch. OpenAI does not ship a mode named Execute.
Codex Has Skills. It Does Not Have /loop.
/skills and $skill-name on Codex. @ on ChatGPT. Keep-going is /goal. Repeats are Automations. /loop is Claude Code.
There Is No Multitask Button.
Parallel work is another cloud chat, a desktop worktree, or /agent. Official docs never name a Multitask button.
Frequently Asked Questions
Ready to go?
Now that Codex is set up, our premium build guides come with pre-written tasks and AGENTS.md files. Just drop them in and let Codex do the work.