Skip to main content

Install Brew on Windows

· 2 min read

This is hands-down the cleanest way to get Brew on Windows.

✅ Recommended: Install Homebrew via WSL (Ubuntu)

Step 1: Make sure WSL is installed

If you haven't installed WSL yet:

  1. Open PowerShell as Administrator and run:

    wsl --install
  2. Reboot your PC if needed.

  3. Launch Ubuntu from your Start menu and finish the setup.

Step 2: Install Homebrew inside WSL

Once you're inside the Ubuntu terminal, run the following:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

During install, it might ask you to install some dependencies. Just follow the prompts.

Step 3: Add Homebrew to your shell profile

After installation, you need to add Homebrew to your shell path.

Run:

echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"' >> ~/.bashrc
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"

If you use Zsh instead of Bash:

echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"' >> ~/.zshrc
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"

Step 4: Confirm it works

brew --version

You should see something like:

Homebrew 4.x.x

Now you’re good to start installing packages with brew install ... just like on macOS.

❌ Native Windows? Nope.

Homebrew doesn't run natively on Windows — not even with Git Bash or Cygwin — and it’s not worth trying to force it. Use WSL.

If you really need a native Windows package manager, try:

  • 🧊 Scoop – lightweight and works via PowerShell
  • 🍫 Chocolatey – great for system-level installs

TL;DR

MethodWorks?Notes
WSL (Ubuntu)Official, supported
Native WindowsNot supported
AlternativeUse Scoop or Chocolatey