Windows GUI tool for switching between multiple Claude Desktop accounts without logging out of any of them.
Built with C# / WinForms on .NET 9. Requires Windows 10+ and the Store (MSIX) edition of Claude Desktop.
Claude Desktop on Windows stores your session as DPAPI-encrypted OAuth tokens inside %APPDATA%\Claude\config.json (keys oauth:tokenCache and oauth:tokenCacheV2). These blobs are tied to your Windows user account on the same machine and are never decrypted — only copied as-is.
ClaudeAccountManager saves those tokens as named profiles and restores them to switch accounts. Before restoring an incoming profile it:
- Stops all Claude processes
- Checkpoints the outgoing session (updates its saved tokens)
- Writes the incoming tokens into
config.json - Clears volatile Electron caches (Local Storage, IndexedDB, Session Storage) so Claude re-reads the new session
- Relaunches Claude Desktop via its App User Model ID (required for Store apps)
Token values are never read, printed, or logged — only copied between files.
| Action | Description |
|---|---|
| Save current | Snapshot the active session as a named profile. Claude stays open. |
| Add account | Snapshot the current session, clear the slate, open Claude for login, then save the new session. No manual logout needed. |
| Switch | Stop Claude, restore a saved profile, relaunch. Outgoing session is checkpointed first. |
| Delete | Remove a profile from disk. |
| Backup | Pack selected data into a timestamped ZIP (Cookies, Desktop history, Code dialogues). |
Profile health is shown in plain text (ready, no token, missing, etc.) — no color-coded status indicators.
- Windows 10 or later
- Claude Desktop — Store (MSIX) edition (installed via Microsoft Store or the MSIX installer)
- .NET 9 SDK — to build from source
git clone https://github.com/svfolder/ClaudeAccountManager.git
cd ClaudeAccountManager
dotnet build ClaudeAccountManager/ClaudeAccountManager.csproj -c Release
Or open ClaudeAccountManager.sln in JetBrains Rider or Visual Studio 2022+.
No NuGet packages are required — only BCL and WinForms.
Profiles are stored at %USERPROFILE%\.claude-swap\:
.claude-swap/
├── profiles/
│ └── <name>/
│ ├── meta.json — tokens, timestamps, observed health
│ └── Cookies — copy of Network\Cookies (best-effort supplement)
├── current — name of the active profile (plain text)
└── config-backups/
└── config.json.YYYYMMDD-HHmmss — auto-backup before every token write
Profile writes are atomic: a temporary stage directory is renamed into place, with a .backup copy retained for recovery if the write is interrupted.
- Works only with the Store (MSIX) edition of Claude Desktop. Win32 installer builds use a different path and are not tested.
- DPAPI-encrypted tokens are machine- and user-bound. Profiles cannot be transferred to another machine or Windows account.
- Backup creates archives only — there is no restore-from-ZIP feature.
- No system tray, hotkeys, or auto-start.
This project was inspired by claude-desktop-swap by FranCalveyra — a cross-platform CLI tool with the same goal. The original project does not support Windows; ClaudeAccountManager is a native Windows GUI reimplementation of the same idea, adapted to how Windows Claude Desktop actually stores its session (DPAPI tokens in config.json rather than a raw Cookies file).
MIT © 2026 svfolder