Claude Code · Tested with aisw v0.3.8 · Desktop v0.2.0 · Updated July 17, 2026
How to Switch Claude Code Accounts
Save each Claude Code account as an aisw profile, then activate the one you need with `aisw use claude <profile>`. aisw applies the stored credentials to the same location Claude Code already reads from and records which profile is active. AI Switcher Desktop exposes the same switch as one click in the Claude Code column.
Claude Code stores its active account in the macOS Keychain or in local files, depending on how it was installed. There’s no built-in way to save a second account and switch back later — you’d normally have to sign out, sign back in, or manually copy credential files. aisw turns each account into a named profile so switching is one command.
Before you start
Install aisw if you haven’t already:
brew tap burakdede/tap && brew install aiswCLI method
1. Save the account you’re currently signed into.
aisw initaisw init bootstraps ~/.aisw/, offers to install the shell hook, and — if it detects you’re already signed into Claude Code, Codex CLI, or Gemini CLI — offers to import each one as a named profile right there in the prompt. Accept the prompt and you’re done with this step. If you skip it, or you already ran init on this machine before, capture the account explicitly:
aisw add claude work --from-live--from-live captures whatever Claude Code account is currently active, without a fresh sign-in. Running aisw init again later is safe — it re-detects live accounts and reports current state without touching profiles you’ve already saved.
2. Add a second account.
If you want to add another account interactively (this opens Claude Code’s native OAuth flow):
aisw add claude personalOr save an API key directly:
aisw add claude work --api-key "$ANTHROPIC_API_KEY"3. Switch between them.
aisw use claude workaisw use claude personalEach use call writes the named profile’s credentials to Claude Code’s live location and records it as the active profile for that tool.
4. Verify which account is active.
aisw statusThis reports the recorded profile and cross-checks it against Claude Code’s live credential state.
Desktop method
AI Switcher Desktop v0.2.0 is publicly available, and the current release assets cover macOS, Windows x64, and Linux x64. Download the matching build from /download/, then follow the same profile-switching flow below.
Screenshot placeholder
AI Switcher Desktop Overview screen with the Claude Code column expanded, showing two profiles and the active one highlighted
- Open AI Switcher Desktop and go to Overview.
- In the Claude Code column, select the profile you want active.
- Click Open Profile, then Activate — or use Quick Switch (⌘K) and type the profile name.
Common problems
If aisw use succeeds but Claude Code still shows the old account, quit and relaunch Claude Code — some installs cache credentials in memory for the running session. If aisw status reports a mismatch between the recorded and live profile, run aisw verify for a full diagnosis and repair path.
If aisw add claude <name> --from-live fails with an error naming a different existing profile, that account is already saved under that other name — aisw checks the underlying Claude identity, not just the profile name, and refuses to create a duplicate. Use the existing profile (aisw use claude <existing-name>) or remove it first if you genuinely want to re-add it under a new name.
If aisw add claude <name> fails with “profile already exists,” that name is already taken by a different account. Either choose a different name or re-run with --yes to overwrite it — overwriting replaces the stored credential, so make sure that’s what you want first.
Frequently asked questions
Does switching profiles log me out of Claude Code?
No. aisw writes the target profile's credentials to the same Keychain entry or local file Claude Code already reads, so the next Claude Code session picks up the new account without an explicit logout step.
Can I switch Claude Code without touching Codex CLI or Gemini CLI?
Yes. aisw use claude <profile> only touches Claude Code's credentials. Use a context if you want to switch all three tools together.