Skip to content
PowerShell Commands

Remove-AppxPackage

Remove-AppxPackage [-Package*] <String> [-AllUsers] [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-AppxPackage [-Package*] <String> [-PreserveApplicationData] [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-AppxPackage [-Package*] <String> -User* <String> [-Confirm] [-WhatIf] [<CommonParameters>]

The Remove-AppxPackage cmdlet removes an app package from a user account. An app package has an .appx file name extension.

Parameters

-AllUsers [<SwitchParameter>]

  • Default value is False
  • Accepts pipeline input False

{{Fill AllUsers Description}}

-Package <String>

  • This value is required
  • Default value is None
  • Accepts pipeline input ByValue

Specifies an AppxPackage object or the full name of a package.

-PreserveApplicationData [<SwitchParameter>]

  • Default value is False
  • Accepts pipeline input False

Specifies that the cmdlet preserves the application data during the package removal. The application data is available for later use.

-User <String>

  • This value is required
  • Default value is None
  • Accepts pipeline input False

{{Fill User Description}}

-Confirm [<SwitchParameter>]

  • Default value is False
  • Accepts pipeline input False

Prompts you for confirmation before running the cmdlet.

-WhatIf [<SwitchParameter>]

  • Default value is False
  • Accepts pipeline input False

Shows what would happen if the cmdlet runs. The cmdlet is not run.

<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,ErrorAction, ErrorVariable, WarningAction, WarningVariable,OutBuffer, PipelineVariable, and OutVariable.

Inputs
System.String[]
Microsoft.Windows.Appx.PackageManager.Commands.AppxPackage An AppxPackage object that contain information, including the full name of the app package.
Outputs
None
Examples
  1. Remove an app package:
    PS C:\>  Remove-AppxPackage -Package "package1_1.0.0.0_neutral__8wekyb3d8bbwe"
    

    This command removes an app package named package1_1.0.0.0_neutral__8wekyb3d8bbwe from the account of the current user.

Additional Notes

This work is licensed under a Creative Commons Attribution 4.0 International. It is attributed to Microsoft Corporation and can be found here.

PowerShell Commands