macOS Keychain dialog appears repeatedly for every new Claude Code session
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Every time Claude Code starts in a new working directory, it creates a new keychain entry (Claude Code-credentials-<hash>) in the macOS Keychain. Each new entry triggers a macOS security dialog asking for permission to access the keychain. Clicking "Always Allow" (Immer erlauben) does not prevent the dialog from reappearing because new entries are created for each directory.
Over time this results in dozens of duplicate keychain entries (I accumulated 23 entries). Even after manually deleting all entries and setting the partition list via security set-generic-password-partition-list to allow all applications, the dialog reappears when Claude Code creates a new entry in a new session.
Actual behavior
A new keychain entry with a unique hash suffix is created per working directory. Each entry triggers its own macOS security dialog. The dialog reappears indefinitely.
Steps to reproduce
Open Claude Code in any directory
Open Claude Code in a different directory
Observe a new keychain entry Claude Code-credentials-<hash> is created each time
macOS prompts for keychain access for each new entry
Environment
macOS version: 25.2.0 (Darwin)
What Should Happen?
Claude Code should reuse a single keychain entry across all sessions and directories, or the "Always Allow" button should permanently suppress the dialog.
Error Messages/Logs
A new keychain entry with a unique hash suffix is created per working directory. Each entry triggers its own macOS security dialog. The dialog reappears indefinitely.
Steps to Reproduce
Open Claude Code in any directory
Open Claude Code in a different directory
Observe a new keychain entry Claude Code-credentials-<hash> is created each time
macOS prompts for keychain access for each new entry
Environment
Claude Model
Sonnet (default)
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
1.12603.1
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Terminal.app (macOS)
Additional Information
_No response_