claude-account CLI
A Linux and macOS CLI that keeps a separate Claude Code profile per account and switches work, personal and SSO in one command
- 79 ★ on the repository
- Last commit
- MIT
Extended access
Why this level
- The utility puts a shim ahead of the `claude` executable in PATH and manages the credential folders of every profile
- The `remove --purge` command permanently deletes profile settings, sessions, plugins and history
Install
- Works in
Manual install
./claude-account installRun after unpacking the release archive; it prints an export PATH line to add to ~/.zshrc or ~/.bashrc.
Access and checks
How we reviewExtended accessThe tool runs code or makes network calls and only reads external data.
- The utility puts a shim ahead of the `claude` executable in PATH and manages the credential folders of every profile
- The `remove --purge` command permanently deletes profile settings, sessions, plugins and history
This is third-party code. Review the repository files before installing.
What it does
claude-account is a Rust utility that puts a small shim in front of the official `claude` and keeps an isolated settings and credentials folder per account. The commands `claude account add work`, `claude account use work`, `claude account list`, `claude account current` and `claude account remove` manage profiles, while every other call such as `claude "fix this bug"` passes through to the real executable unchanged. Login, logout, credential storage and token refresh are done by Claude Code itself, and the utility never reads or copies credential contents. A profile can be created for a regular plan, for SSO with `--sso` or for a console plan with `--console`. A switch affects newly launched processes, and open sessions keep their account.
Who it is for. Developers with several Claude accounts, work, personal and client ones, who are tired of logging out and in whenever the project changes.
Good fit when
- You work under corporate SSO in the morning and a personal account in the evening and want to switch with a command
- A console plan billed by API needs a separate profile next to a regular subscription
- Session history, plugins and settings of each client must sit apart
- A script needs the active profile: `claude account current` prints only the name
- You remove an account and want to log out of it with the official `auth logout`, keeping history for later
Not a fit when
- You use Windows: releases are built only for Linux x86_64 and macOS Intel and Apple Silicon
- You want already open sessions to move to another account at once: a switch affects new launches
- You want to share one account among several people: the tool manages one user profiles
- Claude Code on macOS is older than 2.1.144: profile-scoped Keychain entries are unavailable
Example request
Add a work profile and a personal profile in claude-account, switch to work and show the current oneLimitations
It needs an installed Claude Code, and on macOS version 2.1.144 or newer for profile-scoped Keychain entries. Release archives are built for Linux x86_64 and macOS on Intel and Apple Silicon, checksum-protected but not yet signed or notarized. If Gatekeeper blocks the binary the README advises building from source rather than bypassing the warning. Building needs Rust 1.85 or newer. This is an independent community project: Anthropic did not make it and does not support it. API profiles from `Kerber0ss/claude-account-macos` are not imported in this release.
How to disable. Run `claude account remove NAME` for each profile, then delete the data folders: on Linux `~/.local/share/claude-account/` and `~/.config/claude-account/`, on macOS `~/Library/Application Support/claude-account/`. Remove the `export PATH=...` line from your shell startup file.
FAQ
How do I install claude-account?
Download the archive for your platform from the Releases page, verify the `.sha256`, unpack it and run `./claude-account install`. Add the printed `export PATH=...` line to your shell startup file and open a new terminal.
Does the utility read my tokens?
No. Claude Code handles login, logout, storage and token refresh, and `claude-account` only sets a separate folder per profile and never reads or copies credential contents.
How do I create a profile for SSO or a console plan?
Add a flag: `claude account add company --sso` for SSO or `claude account add api-billing --console` for a console plan. The command opens the official Claude Code login.
What does `remove` do to data?
`claude account remove personal` runs the official `auth logout` inside the profile and unregisters it while settings and history stay. The `--purge --yes` flags delete all profile data permanently.
Where are profiles stored?
On Linux under `~/.local/share/claude-account/profiles/<name>/`, on macOS under `~/Library/Application Support/claude-account/profiles/<name>/`. The `CLAUDE_ACCOUNT_HOME` variable moves all data to one folder.
Discussion
No questions or reviews yet.
Related
CLI toolsA macOS CLI that creates isolated Claude Desktop and Claude Code profiles, each with its own login, chats, settings and icon.
claude-transplant moves Claude Code sessions between Claude Desktop accounts so the sidebar stays full after a switch.
A Claude Code status line showing model, effort level, context fill, git branch and the 5-hour and weekly limits.
claude-sync encrypts and syncs Claude Code sessions between computers through R2, S3, GCS or WebDAV.
A Claude Code panel for several projects: statuses, button decisions, Git, PR, CI and usage limits in one window.
The claude-crusts CLI splits a Claude Code context into six categories, finds waste and writes a /compact command for the session.
README in short
The README calls the utility a profile switcher for Claude Code on Linux and macOS. It lists requirements, installing from a release with checksum verification and building from source, the account commands, the storage layout per system and the recovery path when profile names collide.