How to repair your hard drive with CMD commands and no extra programs
🧠 Many times the problem isn’t Windows, it’s the disk! Damaged sectors, errors in reading, fragmentation or corruption can make your computer slow or unstable. Let’s give it a solution straight from CMD itself.
Step 1: Open CMD as administrator
- Press the Windows key
- Type “cmd“
- Right-click on “Command Prompt” > Run as administrator
Step 2: CHKDSK command (the crown jewel)
This command analyzes and repairs errors on the disk. Let’s go with the most complete one:
chkdsk C: /f /r
C:is your drive letter (change it if you need to check another one)/frepairs errors/rlocates damaged sectors and recovers information
🕐 It will take time depending on the size of the disk and the number of errors. Sometimes it can take hours, but it’s worth it.
If the disk is in use, it will tell you:
“Would you like to schedule this volume to be checked the next time the system restarts? (Y/N)”
Type Y and press Enter. Then restart your PC.
Step 3: Check the disk’s SMART status (with PowerShell)
Want to know if the disk is already showing signs of death? Open PowerShell as administrator and type:
Get-PhysicalDisk
Look at the status: it should say OK. If it says “Warning” or “Unhealthy”, start backing up your data urgently ⚠️
Step 4: Defragment your disk (if it’s an HDD)
It won’t work if you have an SSD, but on mechanical drives it helps:
defrag C: /O
This optimizes and reorganizes files so the disk works faster.
What if there are physical damaged sectors?
CHKDSK can “isolate” those sectors so the system doesn’t use them anymore. But if they keep increasing, your disk is failing physically.
📦 Back up as soon as possible and consider replacing it with an SSD!
Conclusion:
Checking the disk with CMD is free and super useful:
chkdskto repairdefragto optimizeGet-PhysicalDiskto know its health
You don’t need weird programs or to open your computer. And many times, this maintenance revives PCs that seem dead 🧙♂️💾