Switch between multiple Claude Code accounts
To switch between Claude Code accounts, press A in ccdeck: the Accounts panel lists the accounts claude-swap holds, each with its 5-hour and 7-day quota, and Switch makes one active, so new sessions start on it and running ones pick it up on their next message.
You will
- Add a second Claude account
- Compare how much quota each account has left
- Switch accounts yourself, or let auto-switch do it
The film’s lines, in order: Know your limits. Several Claude accounts: switch, add one. Auto-switch stays off until you turn it on. Switch accounts automatically when the active one nears its limit. Sessions already running are not restarted. Every account keeps its own limits. It ends on the ccdeck logo, npx ccdeck, “Switch without the detour.” and ccdeck.dev.
Before you start
- ccdeck running where Claude Code is installed.
- claude-swap, a separate tool that keeps each account's login and usage. When the deck finds Claude Code, it installs claude-swap for you.
- On a Mac, ccdeck started from a Terminal window or at login, not over SSH, so claude-swap can read the Keychain. Otherwise every row says “Keychain unreadable”.
Steps
-
Sign in to a second account
Press A, or click the Accounts icon at the top of the stripe on the left; with Codex installed too, click Claude at the top of the panel. Click + in the panel's header, then Open the sign-in page. Approve the sign-in in the browser tab that opens, as the account you want to add.
Demo data Nothing starts until you click Open the sign-in page. It usually finishes by itself, and the account you were using stays active.
Closing the dialog cancels the sign-in. It puts your previous account back.
More about signing in
- The Claude | Codex switch changes what the panel shows, never the account in use, and the deck remembers it. Codex accounts have a guide of their own.
- Until you approve, Cancel stops the sign-in. If no tab opens, or you closed it, click Open it in this browser.
- Click Paste a code, if the page shows one, paste the code, and click Continue. That happens when the deck is open from another machine.
- The new account's row has no numbers until claude-swap has read its usage.
- If sign-in fails with
not on PATH
, the deck cannot find theclaudecommand. Start the deck withAGENTS_DECK_CLAUDEset to the full path ofclaude. - Over SSH,
ccdeck tuisigns an account in from the terminal, with a link you open in any browser: see Use ccdeck from a terminal or over SSH.
-
Compare the accounts' quota
Click Other accounts, under the active account. Click a row to see its bars and when each window resets.
Demo data Figures turn amber at 70% and red at 90%. A shield marks an organization's telemetry. The deck does not ask Anthropic for these numbers. It shows what claude-swap last read, and says how old that is.
More about the list
- While the list is open, the control reading Slot orders it: by slot, which is claude-swap's own order; by one window, fullest or emptiest first; or by Most room left in each account's fullest window.
- The button beside it opens every row, or shuts them all. This browser keeps both choices.
- A row gets a bar per model too, when claude-swap reports one. Numbers older than 15 minutes are drawn muted.
- With the list shut, hover over Other accounts to see the accounts you could switch to, the one with the most room first.
- A shield beside an address means that account's organization turns on Claude Code telemetry. Hover over it, focus it or click it to read what is sent, and where. It turns amber when your prompts, responses or tool data go too. No shield means the deck has not seen it on, not that it is off.
-
See the total across every account
Click the Account capacity icon, under the Accounts icon. Its dialog says how many accounts are ready, what each window has left on average, and when each account's windows reset.
Open the full-size picture
Demo data The three 5h readings average 27%, so 73% remains. The Reset calendar icon under it shows whose 7-day window resets on each of the next seven days.
Open the full-size picture
Demo data Days and times are in your browser's time zone. More about Account capacity
Neither icon has a key; on a phone, both are under More in the dock. The deck is not told any account's limit, so each account counts the same in the average of their last readings. Click a column's name, a reset column included, to order the rows by it; click it again to turn the order round.
A row is Ready with room in both windows, Limited at the limit of one, Exhausted at both, and Stale when it was never read or its stored login is dead or missing.
A reset time that has passed is not taken as new room: the window keeps its last reading until claude-swap reads it again. In the panel, an open row draws that window as
reset
over an empty bar.The calendar's three buttons list resets read recently, those that need a fresh reading, and times unknown, passed or further off.
-
Switch the active account
Click Switch on the account you want. claude-swap switches, and the account moves to the top, marked with a dot.
New sessions start on it. Sessions already running are not restarted: they pick it up on their next message, up to about 30 seconds later on macOS. A row without Switch says why.
More about switching
- A
/loginin Claude Code changes the active account too: the panel, Switch, Auto-switch and Usage follow the account Claude Code is signed in to. - When that account is not one of yours, a line above the list says so. Click Add account in it, and sign in as that account.
- Switch does not move onto a login claude-swap has seen refused: the row says it expired, with Sign in again, and nothing moves.
- A
-
Turn on auto-switch, or leave it off
Auto-switch starts off. Under Other accounts, click the percentage beside Switch at, click a threshold and save, then turn on the switch. The threshold applies to either the 5-hour or 7-day window.
When a switch is needed, a usable home account comes first, then the rule beside Next account.
More about auto-switch
- Click Set as home in an account's ⋯: Auto-switch takes you there, stays until the threshold, and returns when usable.
- Under Next account, click Most room left or Soonest weekly reset, then save. Weekly picks the earliest eligible reset within 95 hours.
- Both can be set while auto-switch is off; neither does anything until it is on. Use your main Claude Code or Codex account first walks through them.
- Home needs a working login, rotation enabled and usage read within 15 minutes, more than five percentage points below your threshold.
- Use on another paired device does not exclude an account. To exclude one, click Hold out of rotation in ⋯.
- Manual switches stay until the threshold, unless you set Home or a rule again; automatic moves respect cooldowns.
- The engine checks every 60 seconds by default. Custom… accepts 50–99%. A terminal's
cswap autotakes over. - Notifications: Settings › Notifications › Account auto-switched.
-
Rename, move or remove an account
Click ⋯ on the account's row, then Rename, Move to slot… or Remove.
Demo data Projects shows how much the account worked in each project. To take the account to another machine, follow Copy a Claude or Codex login to another machine. A share holds the account's live login, unencrypted, so treat it as a password.
Remove cannot be undone. The first click turns it into Confirm. A second click within four seconds deletes the account's stored login.
More about renaming and moving
The name you save is shown beside the address, and saving the field empty removes the name. A slot is the number claude-swap knows the account by. A slot marked
· swap
is taken, and the two accounts trade places.
If something goes wrong
There is no Claude accounts icon, and A does nothing
The icon is called Accounts. If the stripe shows Codex accounts instead, or no accounts icon, the deck did not find Claude Code when it started, or was started with --no-claude: if Claude Code is installed, start it with --claude. If A alone does nothing, turn on Single-key shortcuts in Settings › Keyboard.
npx ccdeck --claude --ref=guides-claude-accounts
The panel says “claude-swap isn't installed.” or “No accounts added yet.”
If the panel shows a command under the message, run it to install claude-swap; the deck needs no restart. Then click + and sign in.
A row says “Login expired” or “No stored login”
claude-swap's stored login for that account was rejected, or it holds none. Click Sign in on that row, and sign in as that account.
If it says “Login expired on all online decks”, every paired deck that is on and shares the account holds an expired copy too. Sign in again on any one machine that shares it, and the others repair from it within about a minute.
Other accounts says “Auto-switch has nowhere to go”
Every other account is held out or has a dead login. Click Put back in rotation in an account's ⋯ menu, or sign in again to repair one.
Remove does not remove the account
claude-swap declined, most often because a session is running on that account. The menu says why. Switch to another account or end that session, then try again.
Something else? See Troubleshoot ccdeck: status, logs, port and hooks.