Uninstall Guide

How to fully uninstall Homebrew on Mac

Homebrew installs packages, casks, and caches across multiple directories. The official uninstaller handles most of it, but leftover caches and directories can linger. Here's how to remove everything.

6+

Leftover locations

1 – 20+ GB

Typical leftover size

May break dependent apps

Installed packages

What Homebrew leaves behind

Homebrew installs packages in /opt/homebrew (Apple Silicon) or /usr/local (Intel). Caches of downloaded bottles can grow to several gigabytes over time. The official uninstaller removes most files but may leave caches and logs behind.

LocationContents
/opt/homebrew/Homebrew installation directory (Apple Silicon Macs), includes all installed packages
/usr/local/Homebrew/Homebrew installation directory (Intel Macs)
/usr/local/Cellar/Installed formula packages (Intel Macs)
/usr/local/Caskroom/Installed cask apps (Intel Macs)
~/Library/Caches/Homebrew/Downloaded package archives and bottle caches
~/Library/Logs/Homebrew/Installation and build logs

Before uninstalling Homebrew

Many developer tools, terminal utilities, and even GUI apps installed via cask depend on Homebrew. Removing Homebrew will break anything installed through it. Before you uninstall, check what you have:

  • Check top-level packages: Run brew leaves to see formulae that aren't dependencies of other packages — these are what you explicitly installed.
  • Check cask apps: Run brew list --cask to see GUI apps installed via Homebrew. These apps will remain installed but won't receive updates through Homebrew anymore.
  • Export your package list: Run brew bundle dump to save a Brewfile — useful if you ever want to reinstall.

Manual removal (step-by-step)

Warning: Uninstalling Homebrew will remove all packages installed through it. Terminal tools like git, node, python, and others may stop working. Make sure you have alternatives or are prepared to reinstall them.

  1. 1. List your installed packagesOpen Terminal and run brew list to see everything Homebrew has installed. Save this list if you may need to reinstall anything later.
  2. 2. Run the official Homebrew uninstallerExecute this command in Terminal:/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/uninstall.sh)"This removes the Homebrew installation, all formulae, and most associated directories.
  3. 3. Remove leftover cachesDelete the cache and log directories that the uninstaller may leave behind:rm -rf ~/Library/Caches/Homebrew ~/Library/Logs/Homebrew
  4. 4. Clean up remaining directoriesCheck for remaining Homebrew directories: /opt/homebrew/ (Apple Silicon) or /usr/local/Homebrew/, /usr/local/Cellar/, and /usr/local/Caskroom/ (Intel). Only delete these Homebrew-specific directories — other software may also use /usr/local/.
  5. 5. Verify removalClose and reopen Terminal, then run brew --version. If Homebrew is fully removed, you'll see "command not found."

Apple Silicon vs Intel paths

Homebrew uses different installation directories depending on your Mac's processor. If you've upgraded from an Intel Mac or used Migration Assistant, you may have remnants in both locations.

Apple Silicon (M1/M2/M3/M4)

/opt/homebrew/

All packages, casks, and Homebrew itself live under this directory. Removing it clears everything.

Intel Macs

/usr/local/

Homebrew shares /usr/local with other software. Only remove Homebrew-specific subdirectories like Cellar/, Caskroom/, and Homebrew/.

Not sure which processor you have? Click the Apple menu → About This Mac. If it says "Apple M1" (or M2, M3, M4), check /opt/homebrew/. If it says "Intel," check /usr/local/.

Note: Homebrew is a CLI tool, not a .app bundle — Terminal is the right way to remove it. But if you're also cleaning up regular Mac apps, Zapper finds and removes all their hidden leftover files automatically.