How to uninstall programs using the command line or Windows PowerShell

On computers running Windows, users install various application programs to perform certain tasks. Immediately after installation, only basic applications are available in the operating system.

Naturally, this is not enough to perform many activities on a computer. To solve this problem, additional software is installed on the PC.

New programs allow you to perform the necessary operations, make work more comfortable and productive. Gradually, a sick number of different programs are installed on the computer.

Some applications are regularly used, other software is used from time to time, and the rest of the programs are not used for various reasons. Unnecessary programs must be uninstalled from the PC so that they do not take up disk space or affect the performance of the device.

To remove the program from the computer, you can use the Windows system tools or third-party software. You can use any of these methods. Third-party uninstaller applications have additional functionality, this allows them to more thoroughly clean up traces of remote programs on the computer.

In this guide, we will look at one of the ways to uninstall unnecessary applications: uninstalling a program through the command line and uninstalling programs through PowerShell.

Most users are more comfortable using the graphical interface of the Windows uninstaller or uninstaller program. But, there is another method to solve this problem: remove the program from PowerShell or from the command line.

In some cases, you may need to uninstall the program in PowerShell, or uninstall the program using the command line, for example, if uninstalling the application in the usual way fails. Unfortunately, there are situations when, for various reasons, uninstallation of unnecessary software does not occur.

In these cases, you can use the console or a more powerful tool – Windows PowerShell. Removing programs through the Windows command line is performed in the same way in different versions of the operating system: Windows 10, Windows 8.1 (Windows 8), Windows 7.

Please note that not all installed programs are displayed in the console windows, but only those that used the Windows Installer for installation on a PC (installation packages “.msi” of Win32 applications).

First, we’ll see how to uninstall a program using the command line, and then we’ll do the same in Windows PowerShell.

How to uninstall a program via command line

On Windows, uninstalling a program from the command line does not take much time, and it is not a difficult operation even for inexperienced users. You only need to run a couple of commands.

Starting the removal of programs from the command line is performed in the following way:

  1. Run Command Prompt as Administrator .
  2. In the command line interpreter window, enter the command, and then press the “Enter” key:
wmic product get name
  1. After a while, a list of installed applications will appear in the console window.
  2. To start uninstalling programs from the command line, you must run the following command:
wmic product where name="XXX" call uninstall /nointeractive

"XXX" is the name of the program enclosed in double quotes because it appears on the command line.

/nointeractive - option to start uninstalling the program immediately, without invoking additional steps.
  1. When the application is uninstalled, the command line interpreter window will display information about the completion of this operation.

Windows PowerShell – Remove Programs

In addition to the command line, a more powerful tool is built into the Windows operating system – PowerShell. The uninstallation task is performed in a similar way using other commands.

Go through the following steps:

  1. Run Windows PowerShell as Administrator .
  2. In the system tool window, run the command:
Get-WmiObject Win32_Product | ftname,version,vendor,packagename
  1. After executing the command, the shell window will display the applications installed on the PC.
  2. Run the following command:
(Get-WmiObject Win32_Product -Filter "Name = 'XXX'").Uninstall()

'XXX' is the single-quoted program name in a double-quoted construct.
  1. Wait for the program to be uninstalled to complete.

Article Conclusions

Usually, quite a lot of programs are installed on the computer, with the help of which the user solves his problems. Over time, not all applications become necessary or relevant for use at work. Therefore, it makes sense to uninstall unnecessary programs from a PC.

There are several ways to uninstall programs in the Windows operating system. One solution to the problem is to uninstall applications from the command line or from Windows PowerShell.

Leave a Reply

Your email address will not be published.