Skip to content

codex

Terminal coding agent from OpenAI that runs locally, for developers using OpenAI models

Permissive (OSI) · Apache-2.0 AI-native
  • macOS

Listed by , founder & editor

70

Health

Active

Overview

Stars

136,296

Last commit

today

Nov 2026

Repository age

1 year

since Apr 2025

Latest version

rust-v0.172.0

Nov 2026

Contributors

–

27 active in 90 days

Releases

4

last 12 months

Language

Rust

Codex CLI is a coding agent that runs on your own computer from the terminal. It is written in Rust and licensed under Apache-2.0. You start it with the codex command and sign in with a ChatGPT account, or use an API key with extra setup.

You can install it with a shell script on Mac or Linux, a PowerShell script on Windows, npm, or Homebrew cask. Prebuilt binaries for macOS and Linux, on x86_64 and arm64, are on GitHub Releases. OpenAI also offers Codex for VS Code, Cursor and Windsurf, a desktop app and a cloud agent, separate from this CLI.

It is an open source alternative to Claude Code. It is tied to OpenAI models and ChatGPT sign-in. The project began in 2025 and has 39 contributors in the last 90 days.

Who it's for

Developers with a ChatGPT plan

You can sign in with your Plus, Pro, Business, Edu or Enterprise account.

Skip if: You want to use models from other providers.

Terminal-focused engineers

It runs locally in the shell and installs through npm or Homebrew.

Skip if: You prefer working only inside an editor.

Teams that want an Apache-2.0 agent

The permissive license lets you read and build on the code.

Skip if: You need a self-hosted model backend.

The problem it solves

AI coding agents often run only in a hosted editor or closed tool. You may want one in your terminal whose source you can read. Codex CLI runs locally and is open source.

Strengths

  • Apache-2.0 license, written in Rust
  • Installs through script, npm, Homebrew cask or binary
  • Prebuilt binaries for macOS and Linux, x86_64 and arm64
  • Works with a ChatGPT plan or an API key
  • 39 contributors in the last 90 days

Trade-offs

  • Tied to OpenAI models and ChatGPT sign-in
  • API key use needs additional setup
  • Not self-hostable as a service

codex replaces

Self-host codex

Self-hostable
No (desktop or local app)
Hosted plan
Available · pricing

Quick start

npm install -g @openai/codex

From the project's own install instructions. Check the docs for production settings.

Frequently asked questions

Is Codex CLI open source?

Yes. The repository is licensed under Apache-2.0.

Which platforms does it support?

macOS, Linux and Windows, through installer scripts, npm, Homebrew cask or release binaries.

How do I sign in?

Run codex and choose Sign in with ChatGPT. You can also use an API key.

Can I use it in my editor?

The CLI is separate, but OpenAI offers Codex for VS Code, Cursor and Windsurf.

Other Claude Code alternatives

Compare all 8 Claude Code alternatives →

Similar tools in AI coding assistants

Cline

AI coding assistants

Open source AI coding agent for IDE, terminal and desktop, usable with any model

72k 8k yesterday Thriving Apache-2.0

Replaces Claude CodeCursor

pi

AI coding assistants

Terminal coding agent you extend with packages, skills and prompt templates

124k 16k today Thriving MIT

Replaces Claude Code

Goose

AI coding assistants

Open source AI agent with desktop app and CLI that works with 85+ model providers

57k 6.7k today Thriving Apache-2.0

Replaces Claude CoworkClaude Code

Aider

AI coding assistants

Terminal AI pair programmer that commits its edits to git, for use with any LLM

50k 5.2k 6 months ago Dormant Apache-2.0

Replaces Claude Code

T3 Code

AI coding assistants

Desktop, web and phone interface for running Claude Code, Codex and other coding agents

76k 13k today Active MIT

Qwen Code

AI coding assistants

Terminal AI coding agent with MCP, subagents and any OpenAI-compatible model

31k 3.6k today Thriving Apache-2.0