The Ultimate Guide: Format or erase memory cards? And how?
Should you format your (SD) memory card after every use? Do you risk defective pictures and broken videos if you delete data instead of formatting the memory card? And if you format, how and where? You see: A supposed trifle like deleting photos and videos from a memory card is hotly debated all over the internet - including a lot of hearsay and outdated technical background. We want to answer the most important questions and dispel some myths.
NAND Flash: The basics
Unfortunately, to understand the why, some background knowledge is needed about NAND flash memory, as it is used in virtually every memory card. NAND flash is a transistor-based semiconductor memory produced on silicon wafers. Different voltage levels are stored in each individual memory cell. Depending on whether two (1 bit; SLC), four (2 bit; MLC), eight (3 bit; TLC) or 16 different voltage levels are used (4 bit; QLC), a cell can store a corresponding number of bits. Consequently, two (QLC) to eight memory cells (SLC) are needed to store one byte (eight bits).
In order to efficiently address some billions or even trillions of memory cells, these are divided into different levels. There is room for between 512 and 16,384 bytes in a so-called page, i.e. a five-digit number of individual memory cells. Several hundred to a thousand pages then become a block, which can already hold between 512 kilobytes (kB) and 96 megabytes (MB). Several hundred of these blocks are combined into a Plane, on each individual Die (silicon chip) there are usually two to four Planes and several Dies can be in a Package. The package is the memory chip that finally ends up on the PCB in the memory card.
Individual dies and/or planes can be addressed in parallel to enable higher read and above all write speeds. This is why, for example, higher-capacity models are often faster than the smallest variants of a model series.
Important for the problems with deleting and formatting: A page is the smallest level that can be written (program). If a single bit must be stored, a whole page is always addressed. A block is the smallest unit that can be erased. In order to be able to write in a block again, this must have been deleted before completely (strongly simplified).
Why does deleting photos and videos may cost speed?
A problem arises from the latter circumstance. For technical reasons (file system) and to avoid unnecessary Program-Erase Cycle (or short P/E), which limit the service life similar to charge cycles in a battery, the actual data is not deleted immediately when a file is deleted, but the relevant pages are marked as deleted, or more technically invalid. The controller in the memory card will first of all write to blocks and pages that are still free.
Only then is tidying up carried out: the garbage collection or in short GC. To do this, the (valid) content that is still important is read from several blocks with valid and invalid cells and written to a new block. The blocks that have now become free are erased and can be written with new data (program).
However, the garbage collection costs performance: While the data is being cleaned up, new data cannot be written in parallel. Although the interruption often only lasts a fraction of a second and is thus rarely noticed when taking pictures, video recordings with a constant data rush can lead to a recording abort in the worst case - even though Video speed classes with minimum speed requirements usually successfully prevent this from happening.
Do you risk corrupt files if you delete instead of format?
There is no such thing as absolute certainty in life, but away from cheap models or counterfeit products: No, this is extremely unlikely. Apart from the interface, memory cards are almost identical to SSDs in PCs or notebooks. If you are not afraid of deleting files there, you do not need to be with (SD) memory cards either.
Format or delete memory cards?
Deleting can have a negative impact on performance, so clearly format. Right? Yes and no. More precisely, it has to be the right kind of formatting. Because even with the usual quick format, no data is deleted, the file system just "forgets" the position of the files. In terms of performance, there is no difference to deleting photos and videos.
Most cameras use respectively offer optionally another possibility: TRIM or ERASE for memory cards (technically CMD38). While Sony, for example, offers this as the only option, Canon cameras require the "low level format" option to be enabled. With the ERASE command enabled during formatting, the memory card is told that all data is invalid and the controller triggers an erase cycle for all blocks with invalid pages in it. Afterwards, the memory card is practically back in the factory default state and should not show any speed drops.
Those who take few photos and rarely if ever video do not need to format the memory card or delete files at all. Thanks to increasingly affordable prices, for example, it is becoming visibly more popular to use memory cards as part of a back-up strategy. When the memory card is full and all data is copied to the hard drive, a new card is used and the old card goes into the archive - just like the developed 35mm film in the past.
Are there any disadvantages to formatting a memory card?
Indirectly, yes. Those who use the method mentioned in the last section must know that there is no going back. The data is gone and even the best recovery program is powerless. On the other hand, if you accidentally delete a photo and then stop using the card, you have a very good chance of recovering the image with the appropriate programs.
When should I be sure to format my memory card?
Our recommendation: If you have just received a new memory card or changed cameras, you should at least initially format the memory card in the camera.
Can I also format my memory card on the PC or Mac?
In principle, yes, but it is not advisable. No matter if Windows or MacOS: With the default tools you have the choice between a quick format (with no real advantage over deleting the files in the file explorer) or a low-level format that overwrites all cells with 0. The latter sounds like the ERASE command mentioned above and also brings the same final result, but the billions of zeros are actually written, which can take several minutes even with very fast memory cards and puts more P/E cycles on the cells. The detour via the card reader is therefore not worth it.
Those who still want to do it, for example before selling the memory card, should use the official SD Card Formatter. This observes the special structure of SD cards with protected areas and sets up the card according to the SD card standard.