OpenAI Codex Complete Guide

AI Navigate Original / 5/16/2026

共有:

Key Points

  • Codex is an OpenAI coding agent; async "done while you sleep"
  • CLI and Cloud forms; Cloud links GitHub Issue→PR
  • Strengths: async, parallel, GitHub-integrated; weak: cost, supervision
  • AGENTS.md persists rules; Issue-driven, human-review PRs, tests in CI

What Is OpenAI Codex

OpenAI Codex is an AI coding agent OpenAI introduced in 2025. Its biggest trait is "throw a task and it's done while you sleep" async execution. There are CLI and Cloud forms.

2 Forms

1. Codex CLI

A CLI running in the local terminal. Operation feel similar to Claude Code.

2. Codex Cloud (Agent Mode)

Runs in OpenAI's cloud. Links with a GitHub repo and, triggered by Issues or PRs, automatically writes code and submits a PR.

Pricing

  • Included from ChatGPT Plus (USD 20/mo) up
  • Pro (USD 200/mo): greatly increased usage
  • Via API: usage billing, separate

Codex CLI Install

npm install -g @openai/codex
codex login
# Log into OpenAI in the browser

cd your-project
codex

Usage (CLI)

Interactive Mode

$ codex
> What's this project's structure?
> Rewrite the auth module to JWT auth
> Add tests too

One-Line Task

$ codex "make all TypeScript files strict-mode compliant"

Codex Cloud Setup

1. GitHub Linkage

  • chat.openai.com → Settings → Codex → GitHub linkage
  • Select target repos

Sign up to read the full article

Create a free account to access the full content of our original articles.