This cmdlet is part of the Vexasoft Cmdlet Library. You can download it now or click here to find out more.



Uninstalls a product from the local or a remote computer.


  • Uninstall-MSIProduct [-Name] [-ComputerName] [-Credential]


The Uninstall-MSIProduct cmdlet uninstalls products on the local or a remote computer.


  • Name The name of the product to uninstall. Names must be exact and this parameter does not accept wildcards.
  • ComputerName The computer against which to run the cmdlet. By default this parameter will be populated with the name of the local computer.
  • Credential The credentials under which to run the cmdlet. By default this cmdlet will run as the current user. Using this parameter and the Get-PSCredential cmdlet you can specify an alternate set of credentials under which to execute this command.


Uninstall-MSIProduct accepts pipeline input for the Name and ComputerName parameters by property name. This cmdlet also accepts the output of the Get-MSIProduct cmdlet as an input object.


Uninstall-MSIProduct makes changes directly to Windows and does not output any Powershell objects.


The Uninstall-MSIProduct cmdlet requires that the Remote Registry and RPC services are started on the computer it is trying to access, that the WMI Windows Installer Provider is installed (it is an optional component in Windows 2003) and that DNS services are available to resolve target host names.

Example 1

This command will remove the product "MyProduct V1" on the local computer:

Uninstall-MSIProduct -Name "MyProduct V1"

Example 2

This command will remove the product "MyProduct V1" on the remote computer PC01:

Uninstall-MSIProduct -Name "MyProduct V1" -Computer PC01

Example 3

The Get-MSIProduct cmdlet can be used in conjunction with the Uninstall-MSIProduct cmdlet. This command will remove any products with names starting with 'MyProduct' on the remote computer PC01:

Get-MSIProduct -Name MyProduct* -Computer PC01 | Uninstall-MSIProduct