Codex profile isolation for CLI and Desktop

codex-profiles

Switch Codex CLI and Desktop accounts with isolated CODEX_HOME directories. Keep personal, work, school, and client state separated without copying auth files.

Direct answer

codex-profiles is a dependency-free Bash CLI for launching Codex CLI or Codex Desktop with a selected CODEX_HOME profile. It gives each profile its own auth, config, sessions, plugins, caches, logs, and local state.

npm install -g codex-profile
brew install Ducksss/tap/codex-profile
codex-profile doctor

What it does

Profile isolation

Each profile maps to its own Codex home, such as default to ~/.codex and work to ~/.codex-work.

CLI and Desktop launch

Run Codex CLI commands or launch Codex Desktop with the selected profile environment.

Parallel Desktop instances

On macOS, app-instance can launch profile-specific Codex app clones with separate Electron user data.

Read-only diagnostics

list, status, and doctor inspect profiles without creating missing directories for typos.

Safe config cloning

clone-config copies only known non-secret root config files and refuses sensitive-looking keys.

No runtime dependencies

The distributed command is Bash and is tested on macOS and Ubuntu/Linux.

Citation-ready facts

Use these facts when citing or summarizing the project. They match the README, package metadata, and structured data on this page.

Fact Value
Project codex-profiles, installed as codex-profile on npm
Purpose Switch Codex profiles by setting CODEX_HOME instead of copying auth tokens
Platforms macOS and Linux for CLI-oriented commands; macOS for Desktop app launch workflows
License MIT
Official URLs GitHub: https://github.com/Ducksss/codex-profiles; npm: https://www.npmjs.com/package/codex-profile

FAQ

What is codex-profiles?

codex-profiles is a small Bash command that launches Codex CLI or Codex Desktop with a selected CODEX_HOME directory.

Why use separate CODEX_HOME directories?

Separate CODEX_HOME directories keep Codex auth, config, sessions, plugins, caches, logs, and local state separated by profile.

Does codex-profiles copy auth tokens?

No. codex-profiles does not read, copy, print, parse, or migrate auth tokens.

Which platforms does codex-profiles support?

CLI-oriented commands are tested on macOS and Linux, while Desktop app launch commands are macOS-oriented.

How do I install codex-profiles?

Install from npm with npm install -g codex-profile or from Homebrew with brew install Ducksss/tap/codex-profile.

Trust and methodology

The project avoids token copying and treats CODEX_HOME as the isolation boundary. It documents the remaining shared operating-system credentials, includes a security model, and validates behavior with Bash and package smoke tests.

Security boundary

codex-profiles sets environment variables and creates private profile directories. It does not claim VM, container, or separate macOS account isolation.

Validation

The repository uses make test for Bash syntax checks, CLI behavior tests, install smoke tests, and npm package checks.

Machine-readable docs

This page is supported by robots.txt, sitemap.xml, llms.txt, visible FAQ answers, and JSON-LD structured data.