Chocolatey is a powerful package manager for Windows that lets you install, update, and manage software and tools using the command line. It simplifies Windows software management the same way Homebrew does for macOS or apt for Linux.
Chocolatey is ideal for developers, IT professionals, and power users who want to automate software installation, configuration, and upgrades on Windows systems.
β
How to Install Chocolatey on Windows
π Requirements:
- Windows 7 or newer
- PowerShell (v2 or later)
- Administrator access
- .NET Framework 4.5 or later
π§° Installation Steps:
1. Open PowerShell as Administrator
- Press
Win + X
, then choose Windows PowerShell (Admin)
2. Set Execution Policy (Optional but Recommended)
powershell
Set-ExecutionPolicy Bypass -Scope Process -Force
3. Run the Installation Command
Paste and run this one-liner in PowerShell:
powershell
iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
β
Youβll see progress messages as Chocolatey installs.
Once done, you can confirm itβs installed by running:
powershell
choco -v
π Must-Know Chocolatey Commands & Features
π¦ 1. Install Software
powershell
choco install <package-name> -y
Examples:
choco install googlechrome -y
choco install vscode -y
choco install git -y
The -y
flag automatically agrees to all prompts, useful for scripting.
π 2. Search for Packages
powershell
choco search <keyword>
Example:
powershell
choco search firefox
You can also browse available packages at:
π https://community.chocolatey.org/packages
π 3. Upgrade Packages
powershell
choco upgrade all -y
Upgrades all installed packages to the latest version.
Or upgrade a specific package:
powershell
choco upgrade nodejs -y
π§Ή 4. Uninstall Software
powershell
choco uninstall <package-name> -y
Example:
powershell
choco uninstall skype -y
π 5. List Installed Packages
powershell
choco list --local-only
This shows everything youβve installed via Chocolatey.
π οΈ 6. Automate Windows Setup
Chocolatey shines in automating system setups. You can create a script to install all your favorite tools at once:
powershell
choco install googlechrome vscode git nodejs python -y
Save this in a .ps1
script and run it on any new machine!
π 7. Use with Chocolatey GUI (Optional)
Prefer a visual interface? Install the Chocolatey GUI:
powershell
choco install chocolateygui -y
It gives you a point-and-click interface to install, upgrade, and remove packages.
π‘ Tips & Best Practices
- Always run Chocolatey commands as Administrator.
- Use
choco outdated
to check for updates.
- Keep Chocolatey itself updated:
powershell
choco upgrade chocolatey -y
- Great for provisioning developer machines, VMs, or CI environments.
- Combine with Windows Terminal or PowerShell Core for enhanced experience.
π Real-World Use Cases
- Set up a new dev machine in minutes
- Automate installations in IT departments
- Keep software up to date with one command
- Share config scripts with your team
β
Final Thoughts
Chocolatey brings the convenience of Linux/macOS-style package management to Windows. Whether you're installing a new browser or configuring a dev environment with multiple tools, Chocolatey helps you get it done faster, cleaner, and repeatablyβwith just a few commands.
It's ideal for anyone who works on Windows and values automation, speed, and control over their environment. With a large and active community, thousands of packages, and scriptable automation, Chocolatey is an essential tool for Windows power users.