How to Use System File Checker to Repair Windows Files
Windows relies on hundreds of protected system files to run correctly. When one of those files becomes corrupted, missing, or modified, you might see unexpected crashes, error messages, or strange behavior that's hard to trace back to a cause. System File Checker (SFC) is a built-in Windows utility designed specifically for this — it scans protected system files and attempts to repair any it finds damaged.
Understanding how to use it properly, and what to expect from the results, makes it a genuinely useful tool rather than a mystery command you paste from a forum.
What System File Checker Actually Does
SFC scans the integrity of all protected Windows system files. When it finds a corrupted or missing file, it attempts to replace it with a cached copy stored in a compressed folder called the Windows Component Store (located at C:WindowsWinSxS).
It does not scan your personal files, installed applications, or drivers. Its scope is limited to core OS files — which is exactly what makes it useful when Windows itself is behaving badly.
How to Run SFC on Windows 10 and Windows 11
Step 1 — Open Command Prompt as Administrator
SFC requires elevated privileges. The most reliable method:
- Press Windows + S and type
cmd - Right-click Command Prompt in the results
- Select Run as administrator
- Confirm the UAC prompt
You can also use Windows Terminal or PowerShell with administrator rights — SFC works from any of these.
Step 2 — Run the Scan
Type the following command and press Enter:
sfc /scannow The scan runs automatically. It typically takes 10 to 20 minutes, depending on your drive speed and system configuration. A progress bar will fill across the screen — don't close the window or interrupt the process.
Step 3 — Read the Result
When the scan completes, you'll see one of three messages:
| Result Message | What It Means |
|---|---|
| Windows Resource Protection did not find any integrity violations | No corrupted system files detected |
| Windows Resource Protection found corrupt files and successfully repaired them | Issues found and fixed automatically |
| Windows Resource Protection found corrupt files but was unable to fix some of them | Issues found, but SFC couldn't repair everything |
The third result is where most troubleshooting continues.
When SFC Can't Fix the Problem 🔧
If SFC reports it couldn't repair all files, the Component Store itself may be damaged — meaning SFC has nothing clean to pull from. This is where DISM (Deployment Image Servicing and Management) comes in.
Run this command first to repair the Component Store:
DISM /Online /Cleanup-Image /RestoreHealth DISM connects to Windows Update servers to download fresh copies of any corrupted components. This requires an active internet connection and can take longer than SFC — sometimes 20 to 40 minutes.
Once DISM completes, run sfc /scannow again. With a repaired Component Store, SFC has a clean source to work from.
Reviewing the Detailed SFC Log
The result message summarizes findings, but the full log lives in:
C:WindowsLogsCBSCBS.log This file is large and technical, but you can filter it for SFC-specific entries by running this command in an administrator Command Prompt:
findstr /c:"[SR]" %windir%LogsCBSCBS.log > "%userprofile%Desktopsfcdetails.txt" This creates a readable text file on your Desktop showing exactly which files were scanned, flagged, or repaired — useful if you're trying to identify a specific corrupted component.
Running SFC From Outside Windows 💻
If Windows won't boot or is too unstable to run SFC normally, you can run it from the Windows Recovery Environment (WinRE):
- Boot from Windows installation media or access Recovery Mode
- Open Command Prompt from repair options
- Identify your Windows drive letter (it may not be C: in recovery mode —
diskpartandlist volumecan help confirm) - Run:
sfc /scannow /offbootdir=C: /offwindir=C:Windows
Replace C: with the correct drive letter for your Windows installation. This offline mode lets SFC operate on a non-running Windows environment — important for severe corruption scenarios.
Factors That Affect What SFC Can and Can't Fix
Not every system corruption problem falls within SFC's reach, and results vary depending on several conditions:
- Drive health — SFC can't reliably repair files on a failing hard drive. If your drive has bad sectors, underlying hardware issues will continue causing damage after any repair.
- Windows version and update state — SFC behavior and the integrity of the Component Store are tied to which version of Windows is installed and how current its updates are.
- How the corruption occurred — Malware, failed updates, abrupt shutdowns, and driver conflicts each cause different types of damage with different repair outcomes.
- Whether DISM was run first — Running SFC without first repairing the Component Store via DISM can lead to incomplete results on a system where both are damaged.
What SFC Doesn't Cover
SFC is specifically scoped to Windows system files. It won't resolve:
- Corrupted third-party application files
- Damaged drivers (use Device Manager or manufacturer tools for those)
- Registry corruption unrelated to system file integrity
- Hardware-level failures causing instability
For persistent problems that SFC and DISM don't resolve, tools like CHKDSK (for drive-level errors) or Windows Memory Diagnostic (for RAM issues) address different layers of the problem.
Whether SFC solves your issue, partially helps, or comes back clean depends heavily on what's actually wrong — the stability of your drive, the state of your Component Store, how Windows got corrupted in the first place, and whether the real cause is even something SFC is designed to address. The command is simple; diagnosing what comes next is where your specific setup becomes the deciding factor.