How do I know if Windows Update is installed in command prompt?

How do I know if Windows Update is installed in command prompt?

Windows updates are automatically installed and ensure that your Windows the system is up-to-date with the latest security patches, bug fixes and hotfixes.

You can check your Windows Update history by going to Settings > Update & Security > Windows Update and clicking on “View installed update history”. But there’s another way. And it may be faster for you.

You can check your update history using Command Prompt this way:

Type CMD in taskbar search and press Enter.

At the prompt in the Command window enter the following command:

wmic qfe list

And then press Enter.

How do I know if Windows Update is installed in command prompt?

All your updates will be listed in order of installation date. If you’re a Windows PowerShell fan, you’ll be happy to know that you use PowerShell instead of a Command Prompt and achieve the same results.

Skip to content

Windows - List installed updates using the command-line

Home/Windows/Windows - List installed updates using the command-line

Windows - List installed updates using the command-line

Would you like to learn how to list the Windows update packages installed on a computer using the command-line? In this tutorial, we are going to show you how to create a list of hotfixes installed on a computer running Windows using the command-line.

• Windows 2012 R2
• Windows 2016
• Windows 10
• Windows 7

Windows Playlist:

On this page, we offer quick access to a list of videos related to Windows installation.

Don't forget to subscribe to our youtube channel named FKIT.

Tutorial Windows - Get a list of installed updates using the command-line

Start a privileged version of a command-line prompt.

How do I know if Windows Update is installed in command prompt?

Use the SYSTEMINFO command to create a list of Windows updates installed.

Here is the command output.

Optionally, you may create a text file containing the list of Windows hotfix installed.

Congratulations! You created a list of installed Windows updates on a computer using the command-line.

Tutorial Windows - List installed updates using WMIC

Start a privileged version of a command-line prompt.

How do I know if Windows Update is installed in command prompt?

Use the WMIC command to create a list of Windows updates installed.

Here is the command output.

Optionally, you may create a detailed list of Windows hotfixes installed.

Here is the command output.

Congratulations! You created a list of installed Windows updates on a computer using the WMIC command.

VirtualCoin CISSP, PMP, CCNP, MCSE, LPIC22020-10-02T00:28:00-03:00

Page load link

This website uses cookies and third party services. Ok

In Microsoft Windows 10, Windows Update can be found in Settings –> Update & Security –> Windows Update. Normally Windows Update keeps on running in the background and will install new updates automatically.

Windows Update checks for new updates randomly every 22 hours. The reason behind the random check is that if all the systems in the world start checking for updates at the exact same time, this would put extreme load on Microsoft servers. That’s why Microsoft came up with the idea of checking for updates randomly every day.

You can also run Windows Update manually to check for new updates at any time. Here are three ways to check for new Windows updates.

Table of contents

  • Force Windows Update check using Run command dialog
  • Run Windows Update from PowerShell (Command-line)
    • Deploy updates on remote computers
    • Install specific updates only
    • Prevent specific updates from installing
  • Run Windows Update from Command Prompt (Command-line)
  • Check for Windows updates using Windows Settings
  • How to force Windows Update to download already downloaded updates
  • Manage Windows updates using Wuinstall command line tool
  • How to fix corrupted Windows Update

Force Windows Update check using Run command dialog

I found out that the easiest way to force Windows update check is to use a command in the Run dialog. There are other commands from CMD and PowerShell as well, but let’s start with the easiest way to do it.

Open the Run dialog (Windows key + R) or open Windows Search and run the following command:

control update

This will trigger the Windows Update graphical user interface which will start checking for new updates. This method works on all versions of Windows including Windows 10 and Windows 11.

There is another command that will trigger the same effect but only works in Windows 10 and Windows 11:

ms-settings:windowsupdate

There is no official Windows PowerShell module for Windows Update. PSWindowsUpdate is a third-party module that can be used to configure Windows updates in Windows. This module is not installed in Windows by default but you can download it from PowerShell gallery, install and run the module to check for new updates.

There are three steps to running Windows Update through PowerShell. Run the following commands step by step:

Install-Module PSWindowsUpdate
How do I know if Windows Update is installed in command prompt?
Install Module PSWindowsUpdate

This will install the Windows Update module in PowerShell.

Get-WindowsUpdate
How do I know if Windows Update is installed in command prompt?
Get-WindowsUpdate

This command will check for updates.

Install-WindowsUpdate
How do I know if Windows Update is installed in command prompt?
Install WindowsUpdate

This command will install the available updates (which were listed in step 2)

The above mentioned command will only install Windows updates. If you want to update other Microsoft products as well, you’ll need to enable the Microsoft Update Service as well. It’s pretty easy to enable it using PowerShell:

Add-WUServiceManager -MicrosoftUpdate

If you want to automatically restart your computer after installing all the updates, you can run the following command:

Install-WindowsUpdate -MicrosoftUpdate -AcceptAll -AutoReboot

Deploy updates on remote computers

The PowerShell module can also be used to deploy Windows updates on remote computers. There are two commands involved in this process:

1- Create a list of computers and pass the list as a variable string:

$computer = "comp1, comp2, comp3"

2- Now run the following command to start checking for Windows updates on remote computers:

Invoke-WUJob -ComputerName $computer -Script {ipmo PSWindowsUpdate; Install-WindowsUpdate -MicrosoftUpdate -AcceptAll -AutoReboot} -RunNow -Confirm:$false | Out-File "\server\share\logs\$computer-$(Get-Date -f yyyy-MM-dd)-MSUpdates.log" -Force

Install specific updates only

If you already know the Article kb no. of the specific update you want to install, you can run the following command:

Get-WindowsUpdate - KBArticleID "KB5002324", "KB5002325" -Install

Replace the KB number with the one you want to install.

Prevent specific updates from installing

You can prevent specific updates from installing on your computer using the following PowerShell command:

Install-WindowsUpdate -NotKBArticle "KB5002324, KB5002325" -AcceptAll

Run Windows Update from Command Prompt (Command-line)

Windows Update can also be run through legacy CMD to get the latest updates. The only limitation running Windows Update through the command prompt is that it won’t show any progress. Only results are shown when the process is complete. Let’s see how to run it:

RestartDevice – Restart Windows after updates are installed

ScanInstallWait – Check for updates, download available updates and install them

  • Press the Windows key + R to open Run dialog.
  • Type cmd and then press Ctrl + Shift + Enter to open the command prompt in administrative mode.
  • Run the following command to check for new updates:
    wuauclt /detectnow 
  • Run the following command to install new updates
    wuauclt /updatenow

Since the command prompt does not show any progress, a better approach would be to check and install updates at the same time. Here’s the command for this:

wuauclt /detectnow /updatenow

The above-mentioned command will work in all versions of Windows, including Windows 7 and Windows Server 2008 R2. But if you are using Windows 10 or Windows Server 2016, you can use UsoClient command which has more options than wuauclt. You can run UsoClient with the following switches:

StartScan – Start checking for updates

StartDownload – Start downloading updates

StartInstall – Start installing downloaded updates

Check for Windows updates using Windows Settings

To check for new updates and configure your Windows Update settings, follow the steps below:

  1. Open Windows Settings (Windows key + i).
  2. Choose Update & Security.
  3. Choose Windows Update from the left hand menu.
  4. Press the Check for updates button on the right hand pane.
How do I know if Windows Update is installed in command prompt?
Check for updates

How to force Windows Update to download already downloaded updates

If you want to force Windows Update to re-download all the updates again, you can do this using the steps below. There will be times when the updates become corrupted or for other reasons, you just don’t want to install the downloaded updates. In that situation, you can easily delete the already downloaded updates which will for Windows Update to run again and check for and download the updates again.

The only caveat in this situation is that the update must not have been installed on your computer. If the update is already installed, Windows will detect it as installed and will not download it again. In that case, you will need to uninstall the update first and then force Windows Update to run again.

Step 1: Open File Explorer and go to This PC.

Step 2: Open C:\Windows\SoftwareDistribution\Download
This folder contains all the update files that Windows Operating System is currently downloading or recently downloaded and installed.

Step 3: Delete all the files from the above mentioned folder.

Step 4: Run Windows Update again using the above mentioned methods. This will force Windows Update to check for the same updates and download them again. The download and install process for new updates is completely automated. You don’t need to do anything during the download and installation process.

Manage Windows updates using Wuinstall command line tool

Using WuInstall, IT Administrators can automate Windows updates. Wuinstall can be used to enforce Windows Updates inquiries, downloads, and installations at times when they deem them appropriate, enabling them to make the entire update process more controlled and user friendly.

WuInstall is a strong and flexible system management tool that can be used in a WSUS based or standalone environment. To download the latest updates using Wuinstall, you will need to download and install Wuinstall first. Follow the steps below:

Go to http://www.wuinstall.com/ and install the latest free version of Wuinstall on your computer. Open Command Prompt in administrative mode

To search for the latest updates, run the following command:

wuinstall /search

This will not only look for new updates but will also list them in the command window.

To download the updates, run the following command:

wuinstall /download

This will download all the available updates from Microsoft servers.

To install the updates, run the following command:

wuinstall /install

There are a few more switches that you can use with the install command

/quiet – will install updates without showing anything. 

/disableprompt – Disable any input from Windows

/autoaccepteula –  Auto-accept any agreement during update installation

/rebootcycle – Install updates on the next computer reboot.

How to fix corrupted Windows Update

Sometimes Windows Update files get corrupted and the user is not able to download the files again or install the corrupted update files. In that case, we need to run a dism command to fix corrupted Windows Update. Here are the steps:

Open the Command Prompt (Run –> cmd) and run the following command:

dism.exe /Online /Cleanup-image /Restorehealth

After successfully running this command, try force downloading the updates again and the Windows Update should start working again.

Other things you can do with Windows Update:

Disable or bypass pending updates on Windows 10 (and Windows 11)

How to prevent a specific update from installing while allowing all others

How to view and save a list of installed updates in Windows 10 (and Windows 11)

View updates sizes in Windows 10 (and Windows 11)

Download any Windows 10 cumulative update

How to disable automatic restart after installing the updates

How to add update packages to Windows 10 ISO image

How to disable automatic updates

How to limit Windows Update bandwidth usage

How to install updates offline using CAB and MSU files

Hopefully this will be useful in situations where you want to automate certain Windows functions. What other purposes do you want to use command line options to run Windows Update?

Also see:

Usman Khurshid is a seasoned IT Pro with over 15 years of experience in the IT industry. He has experience in everything from IT support, helpdesk, sysadmin, network admin, and cloud computing. He is also certified in Microsoft Technologies (MCTS and MCSA) and also Cisco Certified Professional in Routing and Switching.