Error 0x800f0831 means there is a problem with the Windows Update files (component store or a specific update package). Since DISM already failed, use the simpler, supported repair methods below.
Follow these steps in order.
- Run the basic repair tools
- Open Command Prompt as administrator:
- Click Start, type
cmd.
- Right‑click Command Prompt > Run as administrator.
- In the black window, type these commands one by one and press Enter after each:
DISM /ONLINE /CLEANUP-IMAGE /SCANHEALTH
DISM /ONLINE /CLEANUP-IMAGE /CHECKHEALTH
DISM /ONLINE /CLEANUP-IMAGE /RESTOREHEALTH
Sfc /Scannow
- When all commands finish, restart the PC.
- Try Windows Update again.
If DISM still shows errors or the update still fails with 0x800f0831, continue.
- Fix the specific broken update (easy version)
The error is usually caused by one particular update that is broken or incomplete. The fix is to remove that update and then add it back manually.
Step 1: Find which update is failing
- Go to Settings > Update & Security > Windows Update.
- Try to install updates again and note the KB number of the update that fails (for example, KB4462937). Write it down.
Step 2: Download that update manually
- Open a web browser and go to the Microsoft Update Catalog: https://www.catalog.update.microsoft.com/Home.aspx
- In the search box, type the KB number (for example,
KB4462937) and press Enter.
- In the results, find the entry that matches:
- Your Windows version (Windows 10 version 21H2, 22H2, etc.).
- Your system type (x64 for most PCs).
- Click Download next to the correct entry.
- In the small window that opens, click the link to download the file and save it to C:\temp (create the folder if it doesn’t exist).
Step 3: Expand the downloaded file
- Open Command Prompt as administrator again.
- Run these commands (replace the file name with the one actually downloaded):
cd \
cd temp
expand -F:* windows10.0-kb4462937-x64_9e250691ae6d00cdf677707e83435a612c3264ea.msu C:\temp
- The long file name in the command must match the
.msu file you downloaded.
- After this, there will be a
.cab file in C:\temp with a name like:
-
windows10.0-KBxxxxxxx-x64.cab
Step 4: Remove the broken package (if it is already installed)
This step is for the case where Windows thinks the update is installed but it is corrupted.
- In the same Command Prompt (administrator), run (replace with your actual CAB file name):
Dism /online /remove-package /packagepath:C:\temp\windows10.0-kb4462937-x64.cab
- Restart the computer if asked.
Step 5: Add the package back cleanly
- After restart, open Command Prompt as administrator again.
- Run (again, use your real CAB file name):
Dism /online /add-package /packagepath:C:\temp\windows10.0-kb4462937-x64.cab
- Restart the computer.
- Go back to Settings > Update & Security > Windows Update and try to check for updates again.
If the update was never installed (Windows Update history shows only failures for that KB), you can skip the remove-package step and only run the add-package command with the CAB file.
- If nothing works
If the error continues after the steps above, the official guidance is that an in‑place upgrade repair of Windows may be required. This keeps files and apps but reinstalls the system components so Windows Update can work again.
For that scenario, it is recommended to:
- Back up important files first.
- Then follow the in‑place upgrade instructions for Windows 10 from Microsoft documentation or get direct assistance from Microsoft Support or a local technician.
References: