Multi-Account Login
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.4k
- PR merge metrics
- PR metrics pending
Description
What variant of Codex are you using?
CLI
What feature would you like to see?
Multi Account for Codex CLI , user can switch their account just like we switch profiles on any platform .
User can login with multiple accounts in same machine and then to change dedicated account , just single "codex switch" command works !
Additional information
I already have a working implementation of this (https://github.com/mohitarora8181/codex/tree/feature/multi-account) —
codex login --profile for storing credentials per account,
codex switch [--profile ] for making one the active default,
and a --profile flag that's honored consistently across codex exec, the TUI, login status, and cloud-config bootstrap (via a new auth_home resolution separate from codex_home).
It's backward compatible — no --profile anywhere behaves exactly as today — and I've added test coverage for the login/switch/runtime-profile paths.
Since this repo doesn't accept public PRs, I wanted to raise it as an issue first to check whether this is a direction the maintainers are open to before I clean it up further. Happy to share the diff, a fork link, or open a PR directly if that's useful once there's interest.
A couple of design points I'd welcome feedback on:
Storing profile credentials under $CODEX_HOME/profiles//auth.json and tracking the active one in profiles/state.json — open to a different layout if there's a preferred convention.
Whether codex switch with no --profile should open an interactive picker (what I implemented) or just print usage/error instead.
Whether a default login should auto-mirror into a profiles/default/ profile, or whether that's unnecessary surface area.
Prior art / inspiration: aws --profile, gcloud config configurations.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the referenced feature/multi-account branch and the existing Codex CLI login, switch, exec, TUI, login-status, and cloud-config bootstrap paths. Confirm the maintainers’ preferred credential layout and switch behavior, then use the branch’s login/switch/runtime-profile tests as the completion baseline once the design is accepted.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- authentication, cli
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100