You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Support multiple authenticated accounts per provider with automatic load balancing / failover #36778
Currently OpenCode allows a single authenticated account per provider.
Some users legitimately have multiple subscriptions for the same provider (for example separate personal and work accounts, or multiple family/team subscriptions).
Today, once the active account reaches a rate limit or usage cap, requests fail even though another authenticated account is available.
The only workaround is manually reconnecting or running multiple OpenCode instances.
Proposal
Allow multiple authenticated accounts to be stored for the same provider.
When a request fails due to rate limiting or quota exhaustion, OpenCode should automatically retry with the next available account for that provider.
Ideally the rotation should also support a simple load-balancing strategy so that usage is spread across accounts proactively, not only on failure.
Suggested behavior
opencode auth add <provider> can be called more than once to register additional accounts.
A new subcommand or config section lists all stored accounts per provider and lets the user set a preferred order.
On rate-limit or quota errors, OpenCode transparently retries on the next account before surfacing an error to the user.
Optional: round-robin or random account selection to distribute load before hitting limits.
Why this matters
Many developers have multiple subscriptions (personal, work, family plan, etc.) and currently have no way to use them seamlessly in a single OpenCode session.
Automatic failover would also improve reliability for long-running or batch tasks.
Activity
github-actions commentedon Jul 13, 2026
This issue doesn't fully meet our contributing guidelines.
What needs to be fixed:
[FEATURE]:prefix in the title (e.g.[FEATURE]: Support multiple authenticated accounts per provider...)Please edit this issue to address the above within 2 hours, or it will be automatically closed.
This issue might be a duplicate of existing issues. Please check:
If you believe this was flagged incorrectly, please let a maintainer know.
muhedin998 commentedon Jul 13, 2026
Closing — this is already tracked in #8145, #5391, #23620, and #29085. Subscribing to those instead.