What Is the Thumb DB File? Format & Uses
In this article
The Thumb DB file is a database file that Windows creates automatically to store thumbnail images of pictures, videos, and documents. It is not a file you open or edit yourself; it is a system-generated cache that lets File Explorer show small preview images quickly. The file appears in folders that contain media files, often named Thumbs.db on older Windows versions or thumbcache_*.db on Windows 7 and later. You can safely delete it, but Windows will recreate it the next time you view that folder.
Where Thumb DB Files Come From
Windows has used thumbnail caching since Windows XP. When you open a folder in File Explorer, the system scans for image and video files and generates small previews. To avoid regenerating them every time, it stores those previews in a database file. On Windows XP and Vista, that file was Thumbs.db in the same folder as the media. Starting with Windows 7, Microsoft moved the cache to a central location in your user profile, under %LocalAppData%\Microsoft\Windows\Explorer, with names like thumbcache_32.db and thumbcache_256.db. The number refers to the pixel size of the thumbnails stored in that particular file.
How Thumb DB Files Work
When File Explorer displays a folder, it checks whether a thumbnail already exists for each file. If it does, it loads the image from the database instead of decoding the original file. That is why folders with many images open faster after the first view. The database is a structured storage file, not a simple image folder. It contains metadata about each thumbnail, including the original file name, the timestamp, and the actual image data. If you rename or move a media file, Windows may still show the old thumbnail until it refreshes the cache.
Why You Might See Thumbs.db Files
On modern Windows (7 through 11), you typically do not see Thumbs.db in folders because the system hides system files by default. However, you may encounter it in these situations:
- You have enabled “Show hidden files, folders, and drives” in File Explorer options.
- You are viewing a network share or a USB drive that was used on an older Windows version.
- You copied a folder from an old backup or an external drive that retains the file.
If you see it, it is harmless. It is not a virus, and it does not contain personal data beyond the thumbnails themselves.
How to Delete Thumb DB Files Safely
Deleting Thumbs.db is safe because Windows recreates it as needed. You can delete it manually or use Windows’ built-in Disk Cleanup tool. To delete manually:
- Open File Explorer and navigate to the folder containing the file.
- If you cannot see it, enable hidden files: in the View tab, check “Hidden items” (Windows 10/11).
- Right-click the
Thumbs.dbfile and select Delete. - Empty the Recycle Bin if you want the space freed immediately.
To clear all thumbnail caches at once, use Disk Cleanup:
- Press Windows + S, type “Disk Cleanup”, and open it.
- Select the drive (usually C:), then click OK.
- In the list, check “Thumbnails” and click OK, then Delete Files.
This removes all cached thumbnails for your user account. Windows will rebuild them as you browse folders.
Common Problems and Misconceptions
One common misconception is that Thumbs.db is a virus or malware. It is not. However, because it is a system file, some antivirus programs may flag it if it is stored on a network share or removable drive. If you see a warning, it is usually a false positive. Another issue is that Thumbs.db can become corrupted, causing File Explorer to show blank or wrong thumbnails. In that case, deleting the file fixes the problem because Windows regenerates it. Some users also worry that deleting it will slow down their system. The only effect is that the first time you open a folder after deletion, Windows has to generate new thumbnails, which may take a few seconds longer.
Thumbs.db vs. thumbcache Files
There is a difference between Thumbs.db and thumbcache_*.db. The former is a per-folder file used on Windows XP and Vista. The latter is a centralized cache used on Windows 7 and later. If you are on Windows 10 or 11, you will rarely see Thumbs.db on your local drives, but you might see it on network shares or external drives formatted with FAT32 or exFAT, because those file systems do not support the same hidden attributes. The centralized thumbcache files are stored in your user profile and are managed automatically. You should not delete individual thumbcache files manually; use Disk Cleanup instead, as it handles them safely.
Privacy and Security Considerations
Thumbnail databases can reveal information about the files you have viewed, even after you delete the original files. For example, if you delete a sensitive image, the thumbnail may remain in the cache until it is overwritten. If you share a folder or a USB drive, the Thumbs.db file could expose previews of files that are no longer present. To prevent this, you can disable thumbnail generation entirely or clear the cache regularly. To disable thumbnails in Windows 10/11:
- Open File Explorer, go to the View tab, and click Options.
- In the Folder Options window, go to the View tab.
- Check “Always show icons, never thumbnails” and click OK.
This stops Windows from creating new thumbnail caches. Note that this also disables previews for all folders, which may be inconvenient. For privacy on shared drives, consider using a tool like del /a:h Thumbs.db in Command Prompt to delete hidden files, or simply disable thumbnails before copying folders.
Frequently Asked Questions
Can I delete Thumbs.db?
Yes, it is safe to delete. Windows will recreate it the next time you open the folder in File Explorer. Deleting it does not harm your files or system.
Why is Thumbs.db showing on my USB drive?
USB drives often use file systems like FAT32 or exFAT that do not support Windows’ hidden file attribute the same way NTFS does. As a result, the file appears even when hidden files are not shown. It is harmless and can be deleted.
Is Thumbs.db a virus?
No, it is a legitimate Windows system file. However, malware can sometimes disguise itself with similar names, so if you see a file named Thumbs.db.exe or Thumbs.db.bat, that is suspicious and should be scanned.
How do I stop Windows from creating Thumbs.db?
You can disable thumbnail generation by checking “Always show icons, never thumbnails” in Folder Options. This prevents Windows from creating new thumbnail cache files.
What is the difference between Thumbs.db and thumbcache?
Thumbs.db is an older per-folder cache used on Windows XP and Vista. thumbcache_*.db is the newer centralized cache used on Windows 7 and later. Both serve the same purpose but are stored differently.
Can I open Thumbs.db to view the images?
Not directly. The file is a database, not a standard image format. You would need specialized software to extract thumbnails, but it is not necessary for normal use.