How to fix corrupted SD card using cmd?

By Katrina | Posted to Data Recovery Tips on July 27th, 2020 |

This morning, when I inserted my SD card, I received a damaged SD card error: "The disk is not formatted. Do you want to format it now?" I didn't format the SD card as there are so many important files. How can I fix corrupted SD card? Will it cause data loss?

In this article, we will show you how to fix corrupted SD card using cmd via chkdsk and diskpart.

Note: As you may already know, using cmd to fix corrupted SD card may wipe out all the files. So, please make sure you have a backup. Or, download best free SD card data recovery software - iBoysoft Data Recovery to avoid data loss.

How to fix corrupted SD card using CMD

There are two methods to fix corrupted SD card using CMD.

Method 1: Repair corrupted SD card via chkdsk command

When your SD card is corrupted or damaged, you should firstly do a check disk error within a Windows chkdsk /f command prompt. It can help you fix corrupted SD card file system and make the SD card accessible. With this method, all your files will keep intact.

Step 1: Plug in your SD card to your computer with a card reader.

Step 2: Go to the start menu, type in cmd in a search bar, right click cmd. exe an choose Run as Administrtor.

Step 3: Type in chkdsk *: /f /r /x, replace * with the drive letter you wish to repair. For example, you want to repair G drive, you need to type in chkdsk G: /f /r /x.

Please note that CHKDSK is not available for RAW drives. If you get such a message, try the next method.

Method 2: Fix corrupted SD card with diskpart command

If you want to fix RAW SD card, Diskpart command is a nice choice. But please note it will also forcefully wipe out all the data on the corrupted SD card. So, apply it only when you think that the data in this corrupted SD card is useless.

Step 1: Plug in your SD card to your computer with a card reader.

Step 2: Type diskpart in the search box. Right-click on it and choose Run as administrator.

Step 3: Type list disk and press Enter. According to the list disk information, check which disk is your corrupted SD card. For example, disk 2.

Step 4: Type format fs=ntfs and press enter. If you prefer other file system formats, change the command ntfs to the desired one such as fat32, exfat, etc.

Warning: Please make sure have selected and typed in the correct command as a wrong command may do harm to your computer and data on it.

How to format an SD card on Windows in other ways?

How to fix corrupted SD card without CMD?

If you have important files stored in SD card most of time, a SD card data recovery software is necessary to recover data from damaged SD card. After recovering data from corrupted SD card, we can set our mind at rest to format the corruted SD card and make it working again.

Step 1: Recover data from corrupted SD card

iBoysoft Data Recovery is free data recovery software that allows us recover lost data from corrupted SD card, recover lost data from RAW SD memory card, recover lost data from inaccessible SD memory card, recover lost data from SD memory card showing 0 bytes, recover lost data from unrecognized SD memory card, recover files deleted from SD memory card, recover lost data from not formatted SD memory card, etc. in Windows XP/Vista/7/8/10 and Windows Server 2019/2016/2012/2008/2003.

Tutorial to recover lost data from corrupted SD card:

1. Free download and install iBoysoft Data Recovery on your computer.

2. Launch iBoysoft Data Recovery, choose the corrupted SD card and click "Next". The program will start to scan for lost files on the corrupted SD card.

Recover lost data from corrupted SD card with iBoysoft Data Recovery

3. After the scanning process finishes, you can preview the scanning results and select the files you want to recover.

4. Click the "Recover" button to recover lost data from corrupted SD card.

Now, have a check to ensure all lost data have been recovered.

Step 2: Fix the corrupted SD card by reformatting

After data recovery completed, you can right click the SD card in My Computer, Computer or This PC and select "Format" to format the SD card.

Besides recovering data from corrupted SD card, iBoysoft Dara Recovery is also able to recover lost data from corrupted external hard drives, USB drives, Pen drives, memory cards, as well as recover lost data from inaccessible, unrecognized, unreadable, formatted drives and deleted or lost partitions.