Feature request: Per-project account switching for claude.ai subscription users

Resolved 💬 3 comments Opened Apr 24, 2026 by petermarciniak Closed Jun 16, 2026

Summary

Support configuring different claude.ai subscription accounts on a per-project basis, similar to how apiKeyHelper works for API key users.

Use case

Many users have both a personal claude.ai subscription and a company subscription. Today, switching between accounts requires manually running /login every time you switch projects. There is no way to bind a specific account to a project directory.

Example scenario: A developer has:

  • Personal claude.ai account for personal/open-source projects
  • Company claude.ai account (e.g. tied to their work email) for work projects

They want ~/Code/work-project to always use the company account and all other projects to use the personal account — without manual /login switching.

Proposed solution

Allow a project-level setting in .claude/settings.json to specify which logged-in account to use:

{
  "account": "piotr.marciniak@arrive.com"
}

Claude Code would:

  1. Keep multiple authenticated sessions (already partially supported via /login)
  2. Check the project-level account setting when launching in a directory
  3. Automatically activate the matching session — or prompt the user to log in with that account if not yet authenticated

Alternatives considered

  • apiKeyHelper — only works for API key users, not subscription users
  • Manual /login switching — error-prone and disruptive to workflow
  • direnv + ANTHROPIC_API_KEY — not applicable to subscription auth

Additional context

This is a common workflow in tools like git (per-repo user config), aws-vault (per-profile credentials), and gcloud (per-project configurations).

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗