Bitwarden MCP Server
Published
At a glance
- Category
- Security & auth
- GitHub repository
- bitwarden/mcp-server
- Watch out for
- Bitwarden warns that granting access lets the assistant read passwords and secure notes, and that AI responses may reveal credentials, so vault contents can end up in your model provider's context and logs.
Bitwarden publishes this MCP server itself, as the npm package @bitwarden/mcp-server. It gives an AI assistant two sets of tools. The first wraps the Bitwarden CLI (bw), so the agent can work with your personal or organization vault: items, folders, attachments, Sends and device approvals. The second talks to the Bitwarden Public API for organization admin work such as members, groups, collections, policies and audit events.
It runs locally over stdio, launched by your client with npx or from a local build. The README is blunt that it is meant for local use only and must never be hosted publicly or exposed over a network. Self-hosted Bitwarden instances work too, by pointing two URL variables at your own server.
One detail worth knowing: the tool that opens the vault takes no parameters. When the agent calls it, the server opens a native OS password dialog, and the README says the master password never passes through the MCP protocol or reaches the model.
How it connects
Your AI app
An assistant or agent that supports MCP
Bitwarden MCP Server
Runs as
- npx (Node.js)
Gives the agent
- Vault session
- Item and folder work
- Passwords, TOTP and attachments
- Bitwarden Send
- Organization vault and devices
- Organization administration
Bitwarden
Signs in with
- API key
What it can do
- Vault session
- lock, sync, status and a matching vault-opening tool manage the CLI session. Opening the vault prompts for the master password in an OS dialog on macOS, Linux or Windows.
- Item and folder work
- list and get retrieve items, with create_item, edit_item, delete and restore for logins, notes, cards and identities. create_folder and edit_folder organize them.
- Passwords, TOTP and attachments
- generate creates passwords, get can return TOTP codes, and create_attachment uploads files to an item.
- Bitwarden Send
- create_text_send, create_file_send, list_send, get_send, edit_send, delete_send and remove_send_password manage ephemeral shares.
- Organization vault and devices
- move, create_org_collection, edit_item_collections and confirm handle org items and members, and the device_approval_* tools approve or deny new device logins.
- Organization administration
- Public API tools such as list_org_members, invite_org_member, create_org_group, update_org_policy, get_org_events and import_org_users_and_groups cover admin tasks for Teams and Enterprise orgs.
Setting it up
You need Node.js 22+, a Bitwarden account and the Bitwarden CLI (for example npm install -g @bitwarden/cli). Run bw login, then the CLI's vault-opening command with --raw, to get a session token. In Claude Desktop's claude_desktop_config.json, add a server named bitwarden with command npx, args ["-y", "@bitwarden/mcp-server"] and env BW_SESSION set to that token. For organization admin tools, also set BW_CLIENT_ID (it starts with organization.) and BW_CLIENT_SECRET, taken from the web vault under your organization's Settings, My Organization, API Key. File tools such as create_file_send and create_attachment stay disabled until BW_ALLOWED_DIRECTORIES lists the folders they may touch. Self-hosted users set BW_API_BASE_URL and BW_IDENTITY_URL. You can also build the repo with npm install and npm run build and point the client at dist/index.js with node, and any other client can connect over stdio.
Where each client keeps its MCP config file, and the JSON it expects (cheat sheet)
Where it helps
- Pull the login for a staging service out of the vault while wiring up a local config, without opening the Bitwarden app.
- Generate a 32-character password and save it as a new login item for a site you just signed up for.
- Create a text or file Send to share a secret with a teammate for a limited time.
- List organization members, invite a new admin and add them to the right group and collection.
- Review the latest audit log events and check which organization policies are switched on.
Limitations and things to watch
- Bitwarden warns that granting access lets the assistant read passwords and secure notes, and that AI responses may reveal credentials, so vault contents can end up in your model provider's context and logs.
- The MCP config file holds a live BW_SESSION token and possibly organization API secrets, and the README says never to commit or share it.
- It is built for local use only; Bitwarden says not to deploy it to cloud hosting, containers or public servers, or use it over untrusted networks.
- Write tools can delete items, remove members, change policies and approve device logins, so a misread prompt has real consequences.
- Session tokens expire after inactivity, and on headless machines the vault-opening tool refuses to run, so you fall back to the CLI command with --raw and update the config by hand.
Sources
Written from the project's own documentation, checked November 2026.
- github.com /bitwarden/mcp-server
- github.com /bitwarden/mcp-server/blob/main/README.md
- registry.npmjs.org /@bitwarden/mcp-server/latest
How we research: where our facts come from, how often we re-check them, and why no one can pay for a review or a verdict.