SSH-agent in MacOS not working

Managed to get the SSH agent working fine in Windows with my account following the Bitwarden guide, all went smoothly.

Using the same guide but the MacOS version (I’m unable to link the page)
I cannot get the agent to work in MacOS… I have the app store version installed and I have completed export SSH-AUTH-SOCK etc, I can see the socket (.bitwarden-ssh-agent.sock) file that has been generated in the correct directory and I have “use SSH agent” in the app checked.

When I check communication and type “ssh-add -L” into my terminal I get “The agent has no identities”

I am not self hosting Bitwarden.

Any help greatly appreciated!

Slightly updated output after verifying that SSH_AUTH_SOCK env variable was pointing at the correct file:

❯ echo $SSH_AUTH_SOCK
/Users/************/Library/Containers/com.bitwarden.desktop/Data/.bitwarden-ssh-agent.sock
❯ ssh-add -L
error fetching identities: communication with agent failed

1 Like

Looks like there’s a fix that should be in the next release.

I’m seeing a similar issue.

I tried a couple different things to see how it behaved.

## With Bitwarden closed
❯ ssh-add -L
Error connecting to agent: Connection refused

## Open Bitwarden, but didn't unlock the vault
❯ ssh-add -L
error fetching identities: communication with agent failed

## Unlocked vault
❯ ssh-add -L

# terminal hangs like it's waiting for something
2 Likes

For me “ssh-add -L” just hangs.

Mac App Store: Version 2025.2.1 (38769)

Same problem here. 2025.2.1 App Store version. Connections to the socket just hang.

There haven’t been a new version yet, so this is expected.
According to the Github issue:

Hi! The fix for this issue is merged to the development (main) branch, but not included in a release yet. I don’t have an exact release date at the moment, but I’m guessing it will be either 2025.3.1 or 2025.4.0.

1 Like

its working too, with

export SSH_AUTH_SOCK=~/Library/Containers/com.bitwarden.desktop/Data/.bitwarden-ssh-agent.sock

u did not need to disable the local ssh-agent
thanks for your solution.

regards
tobias