Updating Windows applications is essential for maintaining the latest features and safeguarding your PC against potential vulnerabilities. Yet, many users neglect this task, often due to forgetfulness or a lack of motivation, compounded by the time-consuming nature of the process.
For native Windows applications, the Microsoft Store and Windows Update typically provide a reliable solution, with automatic updates being the norm. However, inconsistencies can arise, and a unified method for updating all programs from a single location remains elusive.
Fortunately, Windows includes a straightforward yet powerful command that allows users to update all applications simultaneously. This command, known as winget—short for Windows Package Manager—enables users to install, update, and remove software directly from the command line, eliminating the need to navigate through a web browser.
To execute a comprehensive update of every app on your PC, simply open PowerShell and enter the following command:
winget upgrade --all
This command checks all applications recognized by winget against the latest available versions, updating any that are outdated. It efficiently handles both traditional installers and Microsoft Store apps in one go, as winget draws from multiple sources, including the winget community repository and the Microsoft Store.
For those who prefer a more selective approach, winget also allows for individual app updates. By appending the app ID to the command, users can update a specific application. For example:
winget upgrade "Chrome"
Additionally, users can view all applications managed by winget, including those not initially installed through it, by running the following command:
winget list
Skipping the confirmation prompts
While winget facilitates the updating of outdated apps, it is not entirely automated. Typically, each update prompts the user for agreement before proceeding. To streamline this process, users can configure the command to bypass these prompts:
winget upgrade --all --accept-source-agreements --accept-package-agreements
However, caution is advised. Although this approach is not inherently dangerous, it may lead to overlooking important license or source terms associated with certain packages, particularly if unexpected permissions are required.
How to automate it
For those comfortable with skipping confirmation prompts, complete automation of the update process is achievable. By creating a task in Task Scheduler that triggers at startup, users can ensure their applications are updated without any manual intervention. Here’s a step-by-step guide:
- Click the search box and type “task scheduler.”
- Open Task Scheduler and select Create Basic Task.
- Name it something like “Winget Auto Update” and click Next.
- Set the trigger to When the computer starts, then click Next.
- Choose Start a program, then click Next.
- In Program/script, enter powershell.exe.
- In Add arguments, enter: -Command “winget upgrade –all –accept-source-agreements –accept-package-agreements”.
- Finish the wizard, then locate the new task in the list, right-click it, and select Properties.
- Under the General tab, check Run with highest privileges, as winget requires elevation for most updates.
- Under Triggers, edit the startup trigger, check Delay task for, and set it to 1 minute. This delay ensures that the task runs after Windows has established a network connection, preventing silent failures.
- Under Conditions, uncheck Start the task only if the computer is on AC power if using a laptop, to avoid missed updates while on battery.
With this setup, every time you boot your PC, the command will automatically search for and install new updates.
Utilizing these winget commands transforms the often tedious task of updating Windows apps into a more manageable process. Moreover, it provides valuable insights into the applications installed on your PC, potentially revealing unused software that can be removed to free up storage space.
Edit: As noted by our readers, winget does not encompass every Windows application. Some apps may not be available through winget. However, it effectively covers the majority of mainstream applications, making it a practical solution for most users.