- DISM and SFC allow you to repair system files and the Windows image without formatting your computer.
- DISM's CheckHealth, ScanHealth, and RestoreHealth parameters analyze and correct the system image online or offline.
- SFC /scannow is the first recommended tool, and when that is not enough, DISM repairs the damaged component store.
- Many DISM errors are resolved by reviewing services, permissions, registry keys, and installation sources used.

When Windows starts to malfunction, the following appear blue screens, rare blockages or errors during updateMany people immediately think of formatting. However, before resorting to that extreme, there are built-in system tools, such as DISM and CFSwhich can leave your Windows installation like new without deleting your files.
In this article you will find a very complete guide, in Spanish and with a tone that is as approachable as possible, to understand What is DISM, and how to use it to repair Windows without reinstalling?, how to combine it with SFC, what to do when DISM gives errors (such as the famous 0x800f0954 or error 50) and, lastly, how to manually replace a system file if there is no other way out.
What is DISM and why is it useful for repairing Windows without formatting?
DISM (Demployment Image Servicing and Management) is a command-line utility included in Windows that handles review and repair the operating system imageThat “image” is the master copy that Windows uses to install components, features, and update itself.
Unlike other tools, DISM can work with both Windows installation that you have booted (online mode) as with offline images in .wim, .vhd or .vhdx formats, very useful when you want to repair a system that won't boot or prepare a custom installation for multiple computers.
Administrators and advanced users rely on DISM to Fix corrupted system files, add or remove packages, drivers, or languagesand to fine-tune Windows PE, Windows RE images or clean installations before deploying them on many computers.
A key detail is that DISM can use as a reference clean system backups stored on Microsoft Update servers or in a local image, allowing you to repair things that other utilities cannot reach, including the system's own component store (.wim).
Administrators and advanced users rely on DISM to Fix corrupted system files, add or remove packages, drivers, or languagesand to fine-tune Windows PE, Windows RE images or clean installations before deploying them on many computers.
A key detail is that DISM can use as a reference clean system backups stored on Microsoft Update servers or in a local image, allowing you to repair things that other utilities cannot reach, including the system's own component store (.wim).
While SFC repairs corrupted files by comparing them to a protected local cacheIf that cache is damaged, SFC is left helpless. That's where DISM comes in. First, repair the parts warehouse. And from there, it already has a healthy base so that SFC can finish fixing the system.

How DISM works to analyze and repair Windows online
DISM is run from the console, either Command prompt (cmd) o PowerShellalways with administrator privileges. To check and repair a Windows installation in use, three main parameters are combined with the option /Online y /Cleanup-Image:
The three key parameters are:
- / Check Health: quick check for any damage already recorded.
- / Scan Health: comprehensive analysis of the component warehouse.
- / RestoreHealth: repairs the image using healthy source files.
In addition, it is added /Cleanup-Image to tell DISM to work on the Windows image, and /Online to tell him to do it on the system that is currently running.
DISM /CheckHealth: Quick image status check
The parameter / Check Health It performs a very light scan of the Windows component store to see if There are previously recorded damagesIt doesn't repair anything, it only informs, and it takes very little time.
To run it, open the Start menu, type cmd, right click on System symbolchoose Run as administratorAccept User Account Control and type the following in the window:
Run CheckHealth:
Dism /Online /Cleanup-Image /CheckHealth
After a few seconds, DISM will tell you if it has detected any signs of corruption in the component vault. If it indicates damage, the next step is a deep scan with / Scan Health.
DISM /ScanHealth: In-depth analysis of the component store
The parameter / Scan Health makes a in-depth scan of all system components which are managed through the component store. It compares the files with their expected hash values, which makes it take considerably longer than CheckHealth.
Command for ScanHealth:
Dism /Online /Cleanup-Image /ScanHealth
Depending on the extent of the system damage and the hardware speed, this analysis can take several minutes. During the process, the results are recorded in various log files, including: DISM.log, Sessions.xml y CBS.logwhich are the reference if you want investigate more specific failures or understand why a repair doesn't turn out well.
DISM /RestoreHealth: Automatic repair of corrupted files
The parameter / RestoreHealth is the one who really tries fix the detected damage in the Windows image. It re-analyzes the image and, when it finds damaged or missing files, replaces them with healthy copies obtained from a trusted source.
RestoreHealth command:
DISM.exe /Online /Cleanup-Image /RestoreHealth
By default, DISM will use Windows Update To download the necessary components, unless otherwise instructed. Depending on the size and severity of the corruption, this process may take a considerable amount of time and consume bandwidth if many files need to be downloaded.
Once finished, if everything goes well you will see a message indicating that The operation has been completed successfully and that the damage has been repaired. From there, it's a very good idea to carry out a SFC /scannow so that the system can finish aligning all the files one by one.
Using DISM to repair Windows images offline
DISM isn't just for the system you have running; it can also work with a Windows installation that is not runningFor example, an image mounted in a folder, a VHD disk, or a USB drive with Windows installed.
This is especially useful when the computer won't start or when you need prepare a reference image which you will then clone on several computers, adding or removing updates, drivers or language packs.
For offline repair you need a valid power supply: install.wim or install.esd files from a Windows ISO or another device, or a pre-prepared image that matches version, edition and language with the installation you want to repair.
Example (offline):
Dism /Image:C:\offline /Cleanup-Image /RestoreHealth /Source:C:\test\mount\windows /LimitAccess
The option /Image: indicates the offline installation path. The parameter /Source: marks the source of the clean files (usually within a mounted install.wim) and /LimitAccess tells DISM that Do not use Windows Update or WSUSbut only the local source.
Running DISM from PowerShell: equivalent cmdlets
If you prefer PowerShell, you have cmdlets available that They replicate practically one by one The functionality of Dism.exe. The operation is the same: you have to open PowerShell with administrator privileges.
In the search box type PowerShell, right click on Windows PowerShell and press on Run as administratorOnce inside, you can use the following commands to work on the online image:
- Check Health:
Repair-WindowsImage -Online -CheckHealth - ScanHealth:
Repair-WindowsImage -Online -ScanHealth - RestoreHealth:
Repair-WindowsImage -Online -RestoreHealth
If you want to see the exact syntax, additional parameters, and examples, in PowerShell you can use the built-in help with a command like Get-Help Repair-WindowsImage -Examples, which will show you more advanced combinations, for example for working with offline images.

SFC vs DISM: Differences and When to Use Each Tool
In Windows you have two command-line tools designed for locate and repair corrupted system files: SFC (System File Checker) y DISMAlthough the goal is similar, the approach is different, and it's important to know when to use each one.
CFS It scans critical system files and compares them to a protected cached copy (Windows File Protection). If it detects that a system file does not match, it marks it as corrupt and replaces it with the healthy version stored in that cache.
DISMInstead, it focuses on the Full Windows image (the component store)It analyzes its integrity by comparing it to a clean image, which can be local or on Microsoft servers, and if it detects problems it attempts to restore the damaged files from that reference image.
Therefore, the practical recommendation is to follow this waterfall strategy:
- First, run SFC /scannow to try to repair system files using the local cache.
- If SFC cannot repair everything, check the message: if it indicates that it could not fix some files, it means that the cache or the store is damaged.
- In that case, launch DISM /Online /Cleanup-Image /RestoreHealth to restore the component warehouse.
- Once DISM has finished, run it again. SFC /scannow so that he can finish polishing the files one by one.
How to run the DISM command in Windows step by step
When the Windows cache that uses SFC is corrupted, it is A visit to DISM is a must.This tool analyzes and repairs the Windows image in bulk, using a clean local or online copy to replace corrupted components.
Flow summary:
- Open the Start menu and type cmd.
- Right click on System symbol and choose Run as administrator.
- In the window, run for example:
dism /online /cleanup-image /restorehealth
If you just want check if there is any damage noted, you can use /checkhealthand for a detailed analysis but without repair, /scanhealthThe most important parameter for a real repair is /restorehealth.
In modern versions of Windows (8, 8.1, 10, 11) this combination works without problems as long as you have an internet connection or a valid installation sourceIn Windows 7, DISM does not have these functions; instead, the following is used: System Update Readiness Tool (SURT)which you can download from the Microsoft catalog to try a similar effect.
Common DISM errors and how to fix them
DISM usually works quite automatically, but sometimes errors occur errors that interrupt the processSome of the most common ones have relatively straightforward solutions.
Error 0x800f0954: DISM failed, no operation was performed
This error usually occurs when something interferes with DISM's access to the source files or to the Windows Update service. Typical causes include:
- Third-party antivirus that blocks system processes or files.
- Windows update services are misconfigured or stopped.
- Using a proxy server that cuts off communication with Windows Update.
- Archive install.wim used as a source with "read-only" permission.
Common solutions:
- Temporarily disable your antivirus software from third parties or even uninstall it while DISM is running. Windows Defender is competent enough to protect the system in the meantime.
- Review and restart services BITS (Intelligent background transfer service), CryptoSvc (Cryptographic services) and Windows Update, making sure that the startup type is automatic.
- Deactivate any proxy configured in the system so that DISM can reach Microsoft servers without restrictions.
- If you use a file install.wim as local sourceRemove the read-only attribute from the file properties before running DISM.
DISM Error 50: Problems with a registry key
Another well-known flaw is the error 50which usually appears when launching commands such as:
Dism /Online /Cleanup-Image /CheckHealthDism /Online /Cleanup-Image /ScanHealthDism /Online /Cleanup-Image /RestoreHealth
The most frequent cause is the presence of a MiniNT registration key misplaced, which makes DISM believe it is running in a limited environment (like WinPE) and blocks certain operations.
Solution (edit the record):
- Open a Command Prompt as administrator and run regedit to open the Registry Editor.
- Navigate to the route
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control. - Locate the folder (key) MiniNT and delete it.
- Close the editor and restart the computer to apply the changes.
After rebootThe above DISM commands should run without displaying error 50, provided there are no other underlying problems.
What to do if DISM gives error 87 or does not recognize /cleanup-image?
El error 87 It usually indicates that one of the parameters passed to the command is incorrect or poorly writtenIt is quite common to see this message when “cleanup-image” has been misspelled, hyphens and slashes have been mixed up, or when the syntax includes spaces where they shouldn't be.
Command examples:
Examples:
DISM /image:C:\ /cleanup-image /restorehealth
DISM /Image:C:\ /ScratchDir:C:\Scratch /Cleanup-Image /Restorehealth /source:wim:F:\sources\install.wim:4 /limitaccess
They can give an error if the path of /Image: It does not point to a valid Windows installation if the directory does not exist. /ScratchDir, if the colon and slashes have been misspelled, or if DISM itself is corrupted on that installation.
In such cases, it is advisable to carefully review the syntax, verify that the indicated drive and paths exist, and that the install.wim image It is compatible with the installed edition, and if you suspect that DISM itself is corrupted, try Run DISM from an installation media or recovery environment pointing to another clean source.
Manually replace a corrupted system file (only as a last resort)
Although the norm is to let SFC and DISM do their job, there are extreme situations where intervention is necessary. manually replace a corrupted system fileIt is a delicate procedure, so it should only be used if there is no alternative and you know exactly which file you want to change.
The general process consists of three steps: Take ownership of the damaged file, grant write permissions, and copy the healthy version. from another part of the system or from a clean source.
Step 1: Take ownership of the system file
In order for an administrator to modify a protected file, they must first assume ownership of the fileIn an elevated Command Prompt, the following command is used:
takeown command:
takeown /f <Ruta_Completa_y_Nombre_de_Archivo>
For example, if the corrupted file is jscript.dll in system32, the command would be:
takeown /f C:\Windows\System32\jscript.dll
Step 2: Grant full permissions to administrators
Once you own the file, you have to grant full access to the administrators group to be able to overwrite it. This is done with:
icacls command:
icacls <Ruta_Completa_y_Nombre_de_Archivo> /grant administradores:F
Or, in English systems, using “administrators” as the group:
icacls C:\Windows\System32\jscript.dll /grant administrators:F
Step 3: Copy the healthy file over the corrupt file
Finally, you copy one correct version of the file from a source you know is clean (another identical Windows installation in terms of version and edition, a mounted image, etc.). The general format is:
copy command:
copy <Archivo_Origen> <Archivo_Destino>
Continuing with the previous example:
copy E:\Temp\jscript.dll C:\Windows\System32\jscript.dll
It is very important to ensure that the source file matches to the same version and build of Windows that you are repairing. Otherwise, you could cause even more serious problems.
If after all this the system still isn't working properly, the corruption may be too deep and it may be time to reassess. Restore the system to a previous point or reinstall Windowsalways making sure to have up-to-date backups.
Have tools like CFS and DISM It allows you to solve a large number of Windows 10 and 11 problems without resorting to the dreaded formatting, and by knowing its parameters, common errors and most useful combinations you can get the most out of them to keep your system stable, repair it when it shows signs of fatigue and leave formatting as the last resort, not the first option.
Editor specialized in technology and internet issues with more than ten years of experience in different digital media. I have worked as an editor and content creator for e-commerce, communication, online marketing and advertising companies. I have also written on economics, finance and other sectors websites. My work is also my passion. Now, through my articles in Tecnobits, I try to explore all the news and new opportunities that the world of technology offers us every day to improve our lives.