Installation
This guide walks you through cloning the Bitwarden Clients repository and installing all necessary dependencies.Prerequisites
Before starting, ensure you have the required software installed:- Node.js: >= 22.12.0 (installation guide)
- npm: ~10 (comes with Node.js)
- Git: Any recent version
Clone the repository
1
Choose your clone method
Clone via HTTPS or SSH based on your GitHub authentication preference:
2
Verify repository structure
Check that the repository cloned successfully:You should see:
Install dependencies
The repository uses npm workspaces to manage dependencies across all applications and libraries.Root installation
- Installs all root dependencies from
package.json - Installs dependencies for all workspace packages (
apps/*,libs/**/*) - Creates a single
node_modulesat the root with hoisted dependencies - Links workspace packages together
- Runs the
preparescript (sets up Husky git hooks)
Installation output
The installation process will:- Download packages
- Set up git hooks
- Link workspaces
Downloads ~1.5 GB of dependencies:
Platform-specific post-install
Some applications require additional setup afternpm install:
- Desktop (Electron)
- Browser extension
- Web vault
- CLI
The desktop app requires rebuilding native modules for Electron:This runs automatically when you
npm install in the desktop directory, but you may need to run it manually after:- Updating Electron version
- Switching Node.js versions
- Installing new native dependencies
Workspace structure
After installation, your workspace will have this structure:Verify installation
Run these commands to ensure everything is set up correctly:Using Node Version Manager (nvm)
If you use nvm, the repository includes an.nvmrc file:
Troubleshooting
Installation fails with permission errors
Solution: Configure npm to install global packages in your home directory:Node version mismatch
Native module build failures
On Windows:Husky hooks not working
If git hooks aren’t running:Disk space issues
The full installation requires ~10 GB of disk space. If you’re low on space:Package lock conflicts
If you encounter package-lock.json conflicts after pulling updates:This should be a last resort. Usually
npm install will automatically resolve lock file issues.Next steps
Now that you’ve installed the repository:1
Build an application
Follow the building guide to compile and run applications
2
Run tests
Verify your setup by running the test suite:
3
Start developing
Check out the contributing guide to learn the development workflow
Additional resources
Requirements
Review detailed system requirements
Building
Build and run applications
Architecture
Understand the monorepo structure
Contributing
Learn the development workflow