PhotoRec is file data recovery software designed to recover lost pictures or lost files from digital camera memory (CompactFlash, Memory Stick, SecureDigital, SmartMedia, Microdrive, MMC, USB Memory Drives...) or even Hard Disks.
PhotoRec is under GNU Public License. It has been integrated into TestDisk distributions since version 5.4.
It searchs for JPEG/JPG, AVI, MOV and some other headers like Canon Raw (CRW). Because there is no data fragmentation (usually), it can recover whole files that are missing.
Since version 5.7, Photorec has been extended to search for non audio/video headers. Here is the full list of recognised headers:
avi: RIFF audio/video
Known limitation: wav files are recovered as avi
bmp: BMP bitmap
Known limitation: prone to false positive, don't try to recover bmp if possible
c: Source code written in C
Known limitation: the signature is not 100% efficient.
dir: FAT subdirectory
Usefull to improve the recovery of fragmented data
doc: Microsoft Office Document
Known limitation: Word, Excel... are all recovered with doc extension.
html: HTML page
Known limitation: the signature is not 100% efficient.
jpg: JPG picture
If paranoid mode is enabled, recovered jpg are checked.
mp3: MP3 audio (MPEG ADTS, layer III, v1)
Known limitation: prone to false positive, don't try to recover mp3 if possible
tar: tar archive
Known limitation: because the tar data is not checked, others headers may stop the recovery of the file.
PhotoRec is safe to use, it will never attempt to write to the drive or memory support you are about to recover from. Recovered files are instead written/stored in the directory from where you are running the PhotoRec (TestDisk) program.