Run your work and personal Claude Code accounts side by side.
One machine. Multiple logins. Zero friction.
Claude Code stores one login per machine. If you have a work account (Team/Enterprise) and a personal account (Pro/Max), you have to /logout and /login every time you switch. That gets old fast.
claude-switch work # launches Claude with your work account
claude-switch personal # launches Claude with your personal accountThat's it. Both can run in separate terminals, simultaneously.
curl -fsSL https://raw.githubusercontent.com/SaschaHeyer/claude-switch/main/install.sh | shOr with Homebrew:
brew install gum # required dependency
curl -fsSL https://raw.githubusercontent.com/SaschaHeyer/claude-switch/main/install.sh | shManual install
# Download
curl -fsSL https://raw.githubusercontent.com/SaschaHeyer/claude-switch/main/claude-switch \
-o ~/.local/bin/claude-switch
# Make executable
chmod +x ~/.local/bin/claude-switch
# Install gum for interactive UI
brew install gumUninstall
curl -fsSL https://raw.githubusercontent.com/SaschaHeyer/claude-switch/main/install.sh | sh -s -- uninstallclaude-switch create work
claude-switch create personalclaude-switch workClaude opens with that profile's account. On first launch, it'll ask you to log in — you only do this once per profile.
Open two terminals:
Terminal 1 Terminal 2
$ claude-switch work $ claude-switch personal
Each runs with its own OAuth session, history, and usage tracking. Your skills, settings, and CLAUDE.md are shared across all profiles.
| Command | Description |
|---|---|
claude-switch <name> |
Launch Claude with that profile |
claude-switch create [name] |
Create a new profile |
claude-switch list |
Show all profiles and login status |
claude-switch delete [name] |
Delete a profile |
claude-switch sync |
Sync project sessions across all profiles |
claude-switch |
Interactive menu |
claude-switch help |
Show help |
Claude Code reads its config from ~/.claude/. Claude Switch creates separate directories (~/.claude-work/, ~/.claude-personal/) and tells Claude which one to use via CLAUDE_CONFIG_DIR.
~/.claude/ ← default profile
~/.claude-work/ ← work profile
~/.claude-personal/ ← personal profile
Shared across profiles (via symlinks):
skills/— your custom skillssettings.json— preferencesCLAUDE.md— global instructionsplugins/— installed plugins
Isolated per profile:
- OAuth credentials (macOS Keychain)
- Session history
- Usage tracking
- Project permissions
Hit your usage limit on one profile? Sync sessions to another and /resume right where you left off:
claude-switch sync # bidirectional sync, all profiles
claude-switch sync --dry-run # preview what would change
claude-switch sync -v # show per-file detailsync copies projects/ and plans/ between all profiles using a "latest wins" strategy — safe to run repeatedly.
Does this work with Claude Pro, Max, Team, and Enterprise?
Yes. Any combination of Claude account types works. A common setup is Team/Enterprise for work + Pro/Max for personal projects.
Can I run both profiles at the same time?
Yes. Each terminal is an independent Claude session with its own login. That's the whole point.
What about my existing Claude setup?
Untouched. Your current ~/.claude/ directory becomes your "default" profile. Claude Switch never modifies it — it only creates new directories alongside it.
Do I need to re-login every time?
No. You log in once per profile. The OAuth tokens are stored in the macOS Keychain and persist across sessions.
What if I want different skills per profile?
By default, skills are symlinked (shared). To use separate skills, remove the symlink and copy the skills directory instead:
rm ~/.claude-work/skills
cp -r ~/.claude/skills ~/.claude-work/skillsDoes this work on Linux?
Yes. The only macOS-specific part is Keychain storage for OAuth tokens. On Linux, Claude Code stores credentials in ~/.claude/.credentials.json, which is already isolated per config directory.
Can I continue a conversation after hitting my usage limit?
Yes. Run claude-switch sync after hitting your limit, then launch a different profile and use /resume to pick up where you left off. The sync copies session files bidirectionally so each profile has a complete view of all conversations.
Does this violate Anthropic's Terms of Service?
No. Claude Switch is a local shell script that manages separate ~/.claude/ config directories. It doesn't touch, extract, or relay any OAuth tokens. It simply sets the CLAUDE_CONFIG_DIR environment variable and launches the official claude binary. All authentication and API calls are handled directly by Claude Code — nothing leaves your machine through claude-switch.
- Claude Code v2.x+
- gum (auto-installed via Homebrew if missing)
- macOS or Linux
- bash 3.2+
Contributions welcome. Open an issue or PR.
MIT
Claude Switch is not affiliated with Anthropic.