How to use winget: install and update apps
winget is the command-line package manager built into Windows 10 and 11. It installs programs from the publisher’s own download address and checks each file against its SHA256 hash.
Check that winget is installed
winget comes with the App Installer package, which Windows 11 and current Windows 10 versions (1809 and later) already include. Open PowerShell or Terminal and ask for the version. If the command is not found, install or update “App Installer” from the Microsoft Store.
winget --versionFind a program
Search by name. The result shows the package name, its ID and the newest version. The ID is what you use in the other commands, because it is unique; names can be ambiguous.
winget search vlcwinget show --id VideoLAN.VLCInstall a program
Install by ID with -e (exact match). winget downloads the installer from the address in the package manifest, compares its SHA256 hash and runs it. Add --silent to hide the installer’s windows, or --scope machine to install for all users (this needs an administrator prompt).
winget install --id VideoLAN.VLC -ewinget install --id VideoLAN.VLC -e --silent --scope machineInstall an older version
List the versions winget knows and pick one with --version. Older versions stay available as long as the publisher keeps the file online.
winget show --id VideoLAN.VLC --versionswinget install --id VideoLAN.VLC -e --version 3.0.20Update programs
winget upgrade lists every installed program for which a newer version exists, including programs you did not install with winget. Update one by ID, or all of them at once. To keep a program at its current version, pin it.
winget upgradewinget upgrade --id VideoLAN.VLC -ewinget upgrade --allwinget pin add --id VideoLAN.VLCUninstall a program
winget uninstall runs the program’s own uninstaller. Use the ID shown by winget list.
winget list vlcwinget uninstall --id VideoLAN.VLC -eMove your programs to a new PC
Export the list of installed programs to a JSON file, copy it to the new PC and import it there. Programs that winget does not know are skipped and listed.
winget export -o apps.jsonwinget import -i apps.json --accept-package-agreementsFrequently asked questions
Is winget safe?
winget is made by Microsoft and is open source. Every package manifest in the community repository is checked before it is accepted, and winget refuses an installer whose SHA256 hash does not match the manifest.
Does winget need administrator rights?
Not for itself. Installers that write to Program Files ask for administrator rights as usual; per-user installers do not.
Where does winget download from?
From the address in the package manifest, which is normally the publisher’s own server or its GitHub releases.