Skip to content

Essential Homebrew commands for installing software on macOS and Linux

Core Package Management

Install software.

brew install <formula>

Install GUI software (Cask).

brew install --cask <cask_name>

Remove (uninstall) software.

brew uninstall <formula>

Upgrade software.

brew upgrade

Remove unneeded dependencies and clear old cache.

brew cleanup

Search and Information

Search for software matching specified strings.

brew search <search_term>

List packages depending on their relation to the system with additional details.

brew info <formula>

List installed packages.

brew list

Show package dependencies.

brew deps <formula>

Repository and Configuration Management

Generate the metadata cache (update Homebrew and formulae).

brew update

Add a new repository (tap).

brew tap <user/repo>

Check system for potential problems.

brew doctor