Repairing Corrupted System Files using SFC & DISM Commands
When Windows experiences random crashes, missing system file warnings, or blue screens, running DISM and SFC can restore system integrity without a clean installation.
Execution order
Always run DISM before SFC. DISM repairs the component store that SFC copies healthy files from, so SFC can only do its job properly once the store is healthy.
1. Open an elevated terminal
Right-click the Start button and choose Terminal (Admin) or Command Prompt (Admin).
2. Repair the Windows image with DISM
DISM /Online /Cleanup-Image /RestoreHealthThis can pause at 20% or 62% for several minutes. That is normal; wait until it reaches 100% and reports that the operation completed successfully.
3. Scan and repair with System File Checker
sfc /scannow4. Restart and re-test
Reboot your PC, then try the program or Windows feature that was failing.
What the SFC result means
- No integrity violations found: your protected system files are healthy; the problem lies elsewhere (drivers, a runtime library, or the application itself).
- Found corrupt files and repaired them: restart and test again.
- Found corrupt files but could not fix some of them: run DISM again, then SFC again. Details are written to
%windir%LogsCBSCBS.log.