iamtheit
Technician

Repair damaged Windows system files (SFC and DISM)

Step 1 of 3

Open Terminal as administrator

Right-click Start, choose Terminal (Admin), then click Yes.

The simulation shows Windows in English, like most laptops.

  1. Open Terminal as administrator

    Right-click Start, choose Terminal (Admin), then click Yes.

    Start (right-click)Terminal (Admin)Yes
  2. Type sfc /scannow and press Enter

    Wait until it reaches 100% (5–20 minutes). Don’t close the window.

    sfc /scannowEnter
  3. Couldn’t fix everything? Run DISM, then sfc again

    Type this DISM command, wait for it to finish, run sfc /scannow once more, then restart.

    DISM /Online /Cleanup-Image /RestoreHealthEnter
Technician fixes (advanced)

The simple steps didn’t help? A technician would try these next, in this order. Stop as soon as the problem is fixed. Commands marked “as administrator”: right-click Start › Terminal (Admin).

  1. Read the result line

    “did not find any integrity violations” = files are fine. “found corrupt files and successfully repaired them” = fixed, restart. “found corrupt files but was unable to fix some of them” = run DISM, then sfc again. “could not perform the requested operation” = run it from Safe Mode.

  2. Check the component store first (as administrator)

    Read-only. “No component store corruption detected” means DISM repair isn’t needed. “The component store is repairable” means run /RestoreHealth.

    DISM /Online /Cleanup-Image /ScanHealth
  3. See exactly which files SFC touched

    Lists the last SFC entries from its log. Lines with “Cannot repair member file” name the files it couldn’t fix; search that file name if the problem stays.

    findstr /c:"[SR]" $env:windir\Logs\CBS\CBS.log | Select-Object -Last 30
  4. DISM fails with 0x800f081f: repair from an ISO (as administrator)

    Download the Windows 11 ISO from microsoft.com, double-click it to mount it (say as drive D:), then run this. DISM takes clean files from the ISO instead of Windows Update. Change D: to the drive letter it gets; if the file is install.esd, use esd: instead of wim:.

    DISM /Online /Cleanup-Image /RestoreHealth /Source:wim:D:\sources\install.wim:1 /LimitAccess
  5. Windows won’t start: run SFC from recovery

    In the blue recovery screen: Troubleshoot › Advanced options › Command Prompt. Type bcdedit | find "osdevice" › first: in recovery the Windows drive is sometimes D: instead of C:; use that letter in the command.

    sfc /scannow /offbootdir=C:\ /offwindir=C:\Windows
Technical details (for the curious)

What SFC checks

System File Checker compares every protected Windows file with a clean copy in C:\Windows\WinSxS and replaces damaged ones. Your personal files and apps are not touched.

Why DISM is sometimes needed first

If the clean copies in WinSxS are damaged too, SFC has nothing to repair from. DISM /RestoreHealth downloads healthy components from Windows Update; then SFC can do its job.

When to use it

Windows suddenly slow or strange, Start or Settings won’t open, updates keep failing, or after a virus. Safe to run at any time.

Coming soon

Still not fixed?

In the next update you can tell us what happened, and our AI helper will suggest another way. Until then, restart the device and go through the steps once more.