When critical Windows system files are missing or corrupted, some Windows features may stop working correctly or Windows may stop responding altogether. If this happens, you can use the Deployment Image Servicing and Management tool (DISM) and the System File Checker tool (SFC) to scan your system files and restore any corrupted or missing files.
Step 1: Run DISM
DISM provides the files required to repair your corrupted files. You should run DISM prior to running the System File Checker. To do this:
Open an elevated command prompt.
Type cmd in the Search box.
In the search results, right-click Command Prompt, and then select Run as administrator.
If you are prompted for confirmation or an administrator password, type the password, or click Allow.
In the Command Prompt window, type the following command and press Enter. It may take several minutes for the command operation to be completed.
DISM.exe /Online /Cleanup-image /Restorehealth
Tips:
DISM uses Windows Update as the source to provide the necessary files. However, if your Windows Update client is broken, you can use a running Windows installation, or a Windows side-by-side folder from a network share or removable media, such as the Windows DVD, as the source of the files. To do this, run the following command instead:
DISM.exe /Online /Cleanup-Image /RestoreHealth /Source:C:\RepairSource\Windows /LimitAccess
In the above command, replace the C:\RepairSource\Windows placeholder with the location of your repair source. For more information about using the DISM tool to repair Windows, see Repair a Windows Image.
Step 2: Run System File Checker
In the Command Prompt window, type the following command, and press ENTER:
sfc /scannow
Command Prompt with administrator rights - sfc /scannow
Warning: Do not close this Command Prompt window until the verification is 100% complete.
The sfc /scannow command will scan all protected system files and replace corrupted files with a cached copy.
https://support.microsoft.com/en-us/topic/use-the-system-file-checker-tool-to-repair-missing-or-corrupted-system-files-79aa86cb-ca52-166a-92a3-966e85d4094e