Installation Guide
Installing Gemini CLI
Get Gemini CLI installed on your system quickly and easily. Choose from multiple installation methods and platform-specific instructions.
System Requirements
Operating System
- • Windows 10/11
- • macOS 10.15+
- • Linux (Ubuntu 18.04+)
- • WSL2 (Windows)
Node.js
- • Node.js 16.0+ required
- • Node.js 18.0+ recommended
- • npm 7.0+ or yarn 1.22+
- • TypeScript support included
Resources
- • 512MB RAM minimum
- • 100MB disk space
- • Internet connection
- • Terminal/Command Prompt
Quick Installation
Install with npm (Recommended)
The most common way to install Gemini CLI. npm comes bundled with Node.js.
Global Installation
npm install -g @google/gemini-cli
Verify Installation
gemini --version
Alternative Package Managers
Yarn
yarn global add @google/gemini-cli
pnpm
pnpm install -g @google/gemini-cli
Bun
bun install -g @google/gemini-cli
Platform-Specific Instructions
Windows
Installation instructions for Windows 10/11 and WSL2
Command Prompt / PowerShell
npm install -g @google/gemini-cli
Windows Security
If you encounter execution policy issues, run:
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
macOS
Installation instructions for macOS using Terminal
Using npm
npm install -g @google/gemini-cli
Permission Issues
If you get permission errors, avoid using sudo. Instead, configure npm to use a different directory.
Linux
Installation instructions for various Linux distributions
Ubuntu/Debian
# Install Node.js
curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash -
sudo apt-get install -y nodejs
# Install Gemini CLI
npm install -g @google/gemini-cli
Verify Installation
Check Version
gemini --version
Should output the current version number, e.g., "2.1.0"
Check Help
gemini --help
Should display all available commands and options
Troubleshooting
Command not found: gemini
If you get "command not found" error:
- Ensure Node.js and npm are properly installed
- Check if npm global bin directory is in your PATH
- Try reinstalling:
npm uninstall -g @google/gemini-cli && npm install -g @google/gemini-cli
- Restart your terminal or run
source ~/.bashrc
Permission denied (EACCES)
If you encounter permission errors:
- Configure npm to use a different directory
- Use a Node.js version manager like nvm
- Consider using local installation instead of global
Installation Complete!
Great! You have successfully installed Gemini CLI. Here is what to do next: