Every once in a while, you’ll find that an update is available for either your macOS system or the apps installed on your machine. It’s important that you keep your system software and apps up to date. This ensures your system is stable and your apps are bug-free.

On a Mac machine, you have several ways to update the operating system and applications. The traditional way to get and install new updates is to use the official Mac App Store on your machine.

However, you’re not tied to it to install your updates. You can also use the Terminal app to find, download, and install various updates on your machine. There are even configurable options letting you decide how these updates should be installed.

Update The macOS Version From Terminal

Terminal has a command that checks for all the available updates for macOS and allows you to download and install them on your machine. The command also lets you update Apple apps such as iTunes on your Mac.

What it doesn’t do though is to install updates for the third-party apps installed on your machine. For those apps, you’re going to need to install a package that is described in the later part of this guide.

Find Available macOS System Updates

The first thing you’ll want to do is check what updates are available for your macOS and Apple apps. Checking doesn’t necessarily mean downloading or installing updates. It’s just to give you an idea what needs to be updated on your Mac.

Launch the Terminal app using your preferred method on your Mac.

When the app launches, type in the following command and press Enter.

softwareupdate -l

It’ll look for all the available updates and display them in your Terminal window. The information you’ll see include the app names, size of the update, whether the update is recommended or not, and whether the update requires rebooting your machine.

You can also check the updates with Terminal and then install them from the App Store, if you want to do it that way.

Download macOS System Updates

After finding out what updates are available, you might want to download those updates to your Mac. Keep in mind that downloading also doesn’t require you to install the updates. You can just keep the updates downloaded and not install them right away.

  • Launch the Terminal app and type in the following command and hit Enter.

    softwareupdate -d -a
  • It’ll download all the available updates but won’t install them. You’ll find these update files in the /Library/Updates/ folder on your Mac.

Install Downloaded macOS Updates

The updates you download using the Terminal command can’t be manually installed. These updates can only be installed using a command in the Terminal app.

To install them, you need to first find out the name of the update and then use that name below to get the update installed on your Mac.

  • Launch the Terminal app, type in the following command, and hit Enter. Make sure to replace update-name with the name of the update you wish to install.

    softwareupdate -i update-name

It’ll let you know when the update is installed on your machine. This shouldn’t take too long as the update is already downloaded on your Mac and it just needs to be installed.

Download & Install All macOS Updates

What you did in the above sections was update things bit by bit. What if you want to find, download, and install all the macOS updates in one go? Well, Terminal has you covered.

There’s a command that lets you install all the available updates on your Mac in a single execution.

  • Open the Terminal app and run the following command in it.

    softwareupdate -i -a

The command will get all updates installed and let you know when it’s done. This’ll take longer than the above methods as it first downloads all the updates and then installs them one by one on your machine.

Update Mac Apps From Terminal

Third-party apps that aren’t developed by Apple require different commands to be updated from the Terminal on your Mac. These app updates won’t show up when you run the commands mentioned above.

In order to be able to update all of your Mac Store Apps, you’re going to need to install Homebrew followed by ‘mas’ on your machine. It’ll then let you update your other apps.

Open the Terminal app and run the following command in it to install Homebrew.

/usr/bin/ruby -e “$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)”

When Homebrew is installed, type in the following command and press Enter to install the mas utility.

brew install mas

When mas is installed, you can run the following command to see a list of all the apps that can be updated using this utility.

mas list

Type in the following command and press Enter to see all the apps that require an update.

mas outdated

Run the following command to update all the outdated apps. It’ll first download updates for all the outdated apps and then install them so expect a good amount of time before it finishes.

mas upgrade

Wait while the utility updates your apps. When it’s done, you can close the Terminal window.

You don’t necessarily need to keep mas and Homebrew installed on your Mac if you don’t plan to update your apps using this way in the future. Uninstalling them won’t affect the updated apps on your Mac so it’s safe to remove them if you want.