uninstall command (winget)

May 19, 2026 ยท View on GitHub

The uninstall command of WinGet uninstalls the specified application.

The uninstall command requires that you specify the exact application name to uninstall. If there is any ambiguity, you will be prompted to further filter the uninstall command to an exact application.

Aliases

The following aliases are available for this command:

  • remove
  • rm

Usage

winget uninstall [[-q] <query>] [<options>]

:::image type="content" source="./images/uninstall.png" alt-text="Screenshot of entering the winget uninstall command in a command line of Windows Terminal." lightbox="./images/uninstall.png":::

Note

When using WinGet to uninstall a package, you may encounter a Microsoft Store agreement. This happens because of how WinGet queries package sources. To avoid Microsoft Store agreement prompts when uninstalling, you can add the --source winget WinGet flag to the winget uninstall command. Alternatively, you can uninstall using Start > Settings > Apps > Apps & features, finding the app you want to remove, and selecting More > Uninstall.

Arguments

The following arguments are available.

ArgumentDescription
-q,--queryThe query used to search for an app.

Note

The query argument is positional. Wild-card style syntax is not supported. This is most often the string of characters you expect to help find the package you are uninstalling.

Options

The options allow you to customize the uninstall experience to meet your needs.

OptionDescription
-m, --manifestMust be followed by the path to the manifest (YAML) file. You can use the manifest to run the uninstall experience from a local YAML file.
--idLimits the uninstall to the ID of the application.
--nameLimits the search to the name of the application.
--monikerLimits the search to the moniker listed for the application.
--product-codeFilters using the product code.
-v, --versionEnables you to specify an exact version to uninstall. If not specified, latest will uninstall the highest versioned application.
--all,--all-versionsUninstall all versions.
-s, --sourceRestricts the search to the source name provided. Must be followed by the source name.
-e, --exactUses the exact string in the query, including checking for case-sensitivity. It will not use the default behavior of a substring.
--scopeSelect installed package scope filter (user or machine).
-i, --interactiveRuns the uninstaller in interactive mode. The default experience shows uninstaller progress.
-h, --silentRuns the uninstaller in silent mode. This suppresses all UI. The default experience shows uninstaller progress.
--forceDirect run the command and continue with non security related issues.
--purgeDeletes all files and directories in the package directory (portable).
--preserveRetains all files and directories created by the package (portable).
-o, --logDirects the logging to a log file. You must provide a path to a file that you have the write rights to.
--headerOptional Windows-Package-Manager REST source HTTP header.
--authentication-modeSpecify authentication window preference (silent, silentPreferred or interactive).
--authentication-accountSpecify the account to be used for authentication.
--accept-source-agreementsUsed to accept the source license agreement, and avoid the prompt.
-?,--helpShows help about the selected command.
--waitPrompts the user to press any key before exiting.
--logs,--open-logsOpen the default logs location.
--verbose, --verbose-logsUsed to override the logging setting and create a verbose log.
--nowarn,--ignore-warningsSuppresses warning outputs.
--disable-interactivityDisable interactive prompts.
--proxySet a proxy to use for this execution.
--no-proxyDisable the use of proxy for this execution.

After you have successfully identified the application intended to uninstall, winget will execute the uninstall command.

Example queries

The following example uninstalls a specific version of an application.

winget uninstall --name powertoys --version 0.15.2

The following example uninstalls an application using its ID.

winget uninstall --id "{24559D0F-481C-F3BE-8DD0-D908923A38F8}"

The following example uninstalls multiple applications.

winget uninstall Microsoft.NuGet Microsoft.Edit

Multiple selections

If the query provided to winget does not result in a single application to uninstall, then winget will display multiple results. You can then use additional filters to refine the search for the application you want to uninstall.

Uninstalling apps not installed with Windows Package Manager

As mentioned in list, the winget list command will display more than just apps installed with the winget. You may still use winget commands to remove these apps from your device.