To fix Windows 10 system problems, perform the repair operation through the recovery environment running command prompt. 1. First, enter WinRE by force shutting down three times or restarting in settings; 2. Select Troubleshooting > Advanced Options > Command Prompt; 3. Run the DISM command (DISM /Image:C:\ /Cleanup-Image /RestoreHealth) to repair the system image; 4. Then run the SFC command (sfc /scannow) to check and replace the corrupt system files; 5. Finally, use CHKDSK (chkdsk C: /f /r) to detect and repair disk errors. These steps can solve most system problems and avoid reinstalling the system.
If you're having trouble with Windows 10 and can't get it running smoothly, using the Command Prompt through recovery tools is a solid option. It's not a magic fix-all solution, but it gives you direct access to system files and repair functions that might save you from a full reinstall.

Accessing Command Prompt from Recovery Environment
First things first—you need to actually get into the Command Prompt. Since Windows isn't booting normally, you'll use the Windows Recovery Environment (WinRE).
- If Windows still boots but has issues, go to Start > Settings > Update & Security > Recovery > Advanced startup > Restart now .
- If it doesn't boot, force it into recovery by interrupting the boot process three times (power off during startup).
Once in WinRE:

- Choose Troubleshoot
- Go to Advanced options > Command Prompt
You'll now have access to a few key commands that can help repair Windows.
Running DISM to Repair System Files
DISM (Deployment Imaging Service and Management Tool) is your first real stop for repairs. It checks and replaces corrupted system files using Microsoft's cached copies.

Basic command:
DISM /Online /Cleanup-Image /RestoreHealth
But if you're offline (like in WinRE), you'll need to adjust it slightly:
DISM /Image:C:\ /Cleanup-Image /RestoreHealth
This can take a while—sometimes 15–30 minutes—dependent on your system and how much needs fixing. Let it run fully before moving on.
A tip: if DISM fails because of connectivity issues or missing sources, you can try adding a Windows 10 ISO as a source manually, but that's more advanced and not always necessary.
Using SFC to Fix Remaining Issues
After DISM finishes, the next step is SFC (System File Checker). This scans system files and replaces incorrect versions with correct ones.
Run this command:
sfc /scannow
Important note: SFC only works if the system files are still intact enough to run the scan. That's why DISM comes first—it fixes the base image so SFC can work properly.
If SFC finds errors, it will attempt to fix them automatically. If it says something like "Windows Resource Protection found corrupt files but was unable to fix some of them," then you'll need to dig deeper or consider other methods.
Checking Disk Errors with CHKDSK
Sometimes the problem isn't system files at all—it's the disk itself. Corrupted sectors or file system issues can mimic OS problems.
To check, run:
chkdsk C: /f /r
Replace C:
with your actual system drive letter if it's different.
-
/f
tells it to fix errors -
/r
locates bad sectors and recovers readable info
It might ask to schedule the check on next reboot—type Y
and restart.
CHKDSK can be slow, especially on large drives, but it's one of those underused tools that can solve seemingly random boot or performance issues.
That's about it. These steps don't guarantee everything gets fixed every time, but they cover most common system-level issues without jumping straight to a reinstall. If none of these work, you may need to look into more targeted solutions based on your specific error messages or hardware status.
The above is the detailed content of How to repair Windows 10 using Command Prompt. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undress AI Tool
Undress images for free

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

If you want to cancel the password login for Windows 11, there are three methods to choose: 1. Modify the automatic login settings, uncheck "To use this computer, users must enter their username and password", and then restart the automatic login after entering the password; 2. Switch to a passwordless login method, such as PIN, fingerprint or face recognition, configure it in "Settings>Account>Login Options" to improve convenience and security; 3. Delete the account password directly, but there are security risks and may lead to some functions being limited. It is recommended to choose a suitable solution based on actual needs.

Like many Windows users, I am always on the lookout for ways to boost my productivity. Command Palette quickly became an essential tool for me. This powerful utility has completely changed how I interact with Windows, giving me instant access to the

There are three main ways to uninstall programs on Windows 11: 1. Uninstall through "Settings", open the "Settings" > "Apps" > "Installed Applications", select the program and click "Uninstall", which is suitable for most users; 2. Use the control panel, search and enter "Control Panel" > "Programs and Functions", right-click the program and select "Uninstall", which is suitable for users who are accustomed to traditional interfaces; 3. Use third-party tools such as RevoUninstaller to clean up more thoroughly, but pay attention to the download source and operation risks, and novices can give priority to using the system's own methods.

To run programs as administrator, you can use Windows' own functions: 1. Right-click the menu to select "Run as administrator", which is suitable for temporary privilege hike scenarios; 2. Create a shortcut and check "Run as administrator" to achieve automatic privilege hike start; 3. Use the task scheduler to configure automated tasks, suitable for running programs that require permissions on a scheduled or background basis, pay attention to setting details such as path changes and permission checks.

This might not be at the top of the list of features people want to return from Windows 10, but it still offers some usefulness. If you'd like to view the current minutes and seconds without turning on that display in the main taskbar clock (where it

Windows 10 KB5061087 is now rolling out as an optional preview update for those on version 22H2 with Start menu fixes.

Microsoft confirmed that the DHCP server service might stop responding or refuse to connect after the June 2025 Update for Windows Server.

In the past, I always viewed the i5 lineup as anemic when it came to gaming. However, in 2025, a mid-range CPU is more than enough to start your gaming journey. Many games still don’t fully utilize multi-core performance as well as they could, so
