softwareupdate · macOS command

On this page 8

softwareupdate is the built-in macOS command that checks Apple’s update catalog, lists available system and security updates, and downloads and installs them from Terminal without opening System Settings. In the Terminal & scripting toolkit of macOS, it is the command-line counterpart of the Software Update pane, and administrators rely on it for scripted maintenance, remote sessions over SSH and troubleshooting when the graphical updater stalls.

The tool lives at /usr/sbin/softwareupdate, ships with every Mac, and talks to the same Apple software update service as the graphical interface. It can also fetch full macOS installers and install Rosetta 2 on Apple silicon, which makes it a common building block in deployment and repair scripts.

How softwareupdate finds and applies updates

softwareupdate works by querying the Apple update catalog, comparing the offered products with what is installed, and then downloading signed packages that the system verifies before applying them. Each offered product has a label, a version string, a size and flags that indicate whether it is recommended and whether it requires a restart.

Since macOS Big Sur, system updates use the sealed system volume design, so the tool no longer copies files into place directly. Instead, it prepares an update snapshot and hands it to the system, which finishes the work during a restart. Smaller items such as Safari, XProtect data or Command Line Tools may install without any restart.

The following table summarizes the stages the command goes through during a typical install.

StageWhat happensTypical duration
Catalog scanReads available products from Apple serversA few seconds
DownloadFetches signed packages to local storageMinutes, depends on size and bandwidth
PreparationVerifies and stages the update5 to 30 minutes for major updates
Apply and restartBoots into the updater and seals the volume10 to 40 minutes
Stages of a softwareupdate run

Key options of the softwareupdate command

The command is controlled by a small set of flags, and most daily use combines listing, installing and restarting. Installing requires administrator rights, so install commands are normally run with sudo.

FlagPurposeNote
-l or --listLists available updates and their labelsNo admin rights needed
-i with a labelInstalls one named updateLabel must match exactly
-i -aInstalls all available updatesIncludes major restart items
-i -rInstalls only recommended updatesSkips optional items
-dDownloads without installingUseful before a maintenance window
-RRestarts automatically if requiredInterrupts logged-in users
--historyShows previously installed updatesHelpful for audits
--install-rosettaInstalls Rosetta 2 on Apple siliconAdd --agree-to-license in scripts
Frequently used softwareupdate flags

Two further options matter for imaging and upgrades. --list-full-installers shows the complete macOS installers that Apple offers for the current hardware, and --fetch-full-installer --full-installer-version places a chosen Install macOS application in the Applications folder, where it can be used to create bootable media or run an in-place upgrade.

softwareupdate compared with other update methods

softwareupdate is one of several update paths on a Mac, and each path suits a different scale of management. The command shares its back end with the graphical pane but offers automation and remote access that the pane lacks.

MethodBest suited forMain limitation
Software Update paneIndividual users at the deskManual, no scripting
softwareupdate commandScripts, SSH sessions, repairsNeeds local credentials on Apple silicon
MDM update commandsFleets enrolled in device managementRequires an MDM server
Declarative Device ManagementEnforced deadlines across many MacsRequires recent macOS and MDM support
Full installer appClean installs and bootable mediaLarge download of 12 GB or more
Ways to update macOS

Related tools in the Terminal & scripting topic often appear in the same scripts. launchctl schedules a script that calls softwareupdate, caffeinate keeps the Mac awake during a long download, and pmset controls the sleep behavior that might otherwise interrupt an unattended update.

Authentication on Apple silicon Macs

On Apple silicon, installing a macOS update requires authorization by a volume owner, which is a user who holds a secure token. Root privileges through sudo alone are not sufficient for system updates, a change that surprises many administrators coming from Intel Macs.

For interactive use, the command prompts for the password. For scripts, the --user and --stdinpass options pass an owner account and its password through standard input, but storing such credentials in scripts is a security risk. In managed fleets, a bootstrap token escrowed to MDM lets the management server authorize updates instead, which is the preferred approach.

Common problems and how to fix them

Most failures come from network filtering, insufficient disk space or authentication, and the error text usually points to the cause. The following table maps frequent symptoms to their fixes.

SymptomLikely causeFix
No updates found despite a newer releaseDeferral policy or a cached catalogCheck MDM deferrals and run the list again
Download stops partwayProxy or firewall blocking Apple hostsAllow Apple update domains
Install fails on Apple siliconNo volume owner authorizationAuthenticate with a secure token user
Preparation never completesLess than about 25 GB free spaceFree storage and retry
Label not recognizedTyping error or changed labelCopy the label from the list output
Troubleshooting softwareupdate

Apple has removed or restricted several older options over time, including the ability to ignore major macOS upgrades with --ignore. Scripts written for older releases should therefore be tested on each new macOS version before broad use.

Good practice for scripted updates

  • Run softwareupdate -l first and parse labels rather than hardcoding them.
  • Use -d to pre-download updates during working hours and install them later.
  • Warn users before using -R, because the restart closes open work.
  • Log output to a file so that failures can be audited afterward.
  • Prefer MDM and declarative management for enforcement across a fleet.

Stripped to the essentials

softwareupdate is a text command for updating a Mac. It does the same job as the Software Update button in System Settings. You type it in Terminal instead of clicking.

It can show which updates exist. It can download them. It can install them and restart the Mac. The main benefit is automation: a script can update a Mac at night or over a remote connection. On newer Macs, it still asks for the password of an authorized user before a big system update.

Where it is applied

An IT technician at a design studio supports 15 Macs, and several users ignore update reminders for weeks. The technician connects to each Mac over SSH and runs softwareupdate -l to see which security updates are pending. On one Mac, the list shows a point release of about 1.5 GB that requires a restart.

The technician runs sudo softwareupdate -d -a during the day to download the update in advance. In the evening, the install command with -R applies it after the user has left. A short script that wraps the same commands and runs through a launch daemon then repeats the process weekly. As a result, the studio’s Macs stay within one week of each security release without anyone opening System Settings.