How to block the automatic cleaning of Windows 10's Thumbnail Cache - gHacks Tech News

How to block the automatic cleaning of Windows 10's Thumbnail Cache

Microsoft's Windows operating system uses a thumbnail cache for thumbnail icons used in Explorer to speed up the display of icons when a user opens a folder with cached items.

Microsoft changed how the thumbnail cache works in the Fall Creators Update for Windows 10. Starting with that release, Windows 10 clears the thumbnail cache automatically using a feature called Automatic Maintenance.

Automatic Maintenance

Automatic Maintenance performs a large number of tasks, from synchronizing the time and maintaining Windows Defender to defragmentation of drives and clean-up operations.

Tip: Open PowerShell and run the command Get-ScheduledTask | ? {$_.Settings.MaintenanceSettings} | Out-GridView to display all Automatic Maintenance tasks and the status of each in a listing.

One such task is called SilentCleanup. The task launches the built-in Disk Cleanup tool using the parameter /autoclean which makes the tool read Registry values to determine what to clean.

Cleaning the cache may free up storage on the device but it comes at the cost of having to renew the cache when File Explorer is used.  Windows 10 users who keep lots of photos in a single folder may experience issues when those folders are opened in File Explorer as it may increase the CPU load for the time it takes to generate and cache the thumbnails.

You can visit the hidden folder %userprofile%\AppData\Local\Microsoft\Windows\Explorer in Explorer to display the cache.

Option 1: Making changes to the Registry

thumbnail cache autorun delete

SilentCleanup checks the data of each Autorun Dword value under HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\ and HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\ to determine whether it should include that cache in the cleanup operation.

A value of 0 blocks the maintenance task from deleting the cache, a value of 1 allows it to to so.

Here is how you configure Windows 10 to block or allow the clearing of the cache:

  1. Open Start, e.g. by clicking on the icon or tapping on the Windows-key on the keyboard.
  2. Type regedit.exe.
  3. Confirm the UAC prompt that Windows displays.
  4. Go to HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\Thumbnail Cache
  5. Double-click on the Autorun Dword value.
  6. Set it to 0 to prevent Windows from clearing the cache, or to 1 to allow it to do so.
  7. Go to HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\Thumbnail Cache
  8. Double-click on the Autorun Dword value.
  9. Set it to 0 or 1 accordingly.
  10. Optional: repeat the steps for any other cache listed under VolumeCaches.
  11. Restart the PC.

Windows won't delete the cache anymore as part of Automatic Maintenance if you set both entries to 0.

Option 2: The Task Scheduler

You may disable the entire SilentCleanup task or even Automatic Maintenance in the Task Scheduler. Disabling SilentCleanup may be an option if you don't want Windows to clear the cache automatically.

You may still run Disk Cleanup or any third-party tool that supports the cleaning of Windows caches to do so. Note that used disk space my increase if you don't as Windows won't run the cleanup task anymore.

  1. Open Start.
  2. Type Task Scheduler and load the result. You may also search for taskschd.msc directly if Windows Search acts up and does not reveal the right result in the search results.
  3. Use the navigation in the sidebar to go to Task Scheduler Library > Microsoft > Windows > DiskCleanup
  4. Right-click on the SilentCleanup task on the right and select Disable from the context menu; this turns the task off so that it is not run automatically anymore.

Tip: You can turn the task back on at any time by following the steps described above and selecting Enable from the context menu.

Summary
How to block the automatic cleaning of Windows 10's Thumbnail Cache
Article Name
How to block the automatic cleaning of Windows 10's Thumbnail Cache
Description
Find out how to prevent Windows 10 from deleting cached thumbnails automatically to avoid the recreation in future sessions.
Author
Publisher
Ghacks Technology News
Logo
Advertisement

We need your help

Advertising revenue is falling fast across the Internet, and independently-run sites like Ghacks are hit hardest by it. The advertising model in its current form is coming to an end, and we have to find other ways to continue operating this site.

We are committed to keeping our content free and independent, which means no paywalls, no sponsored posts, no annoying ad formats or subscription fees.

If you like our content, and would like to help, please consider making a contribution:


Previous Post: «
Next Post: »

Comments

  1. Dave said on March 4, 2019 at 3:22 pm
    Reply

    I just open WinAero Tweaker and check the box next to “Keep Thumbnail Cache”.

    1. -1 said on March 4, 2019 at 6:00 pm
      Reply

      +1

  2. Paul(us) said on March 4, 2019 at 6:14 pm
    Reply

    Martin ( Or anybody else who know’s) do you have roughly speaking any idea when you have a large number of pictures ( Let see 100.000) how large the thumbnail cache will become?
    And does not cleaning also have possible have side effects like possible running out of cache room?

    1. Yuliya said on March 4, 2019 at 10:53 pm
      Reply

      Never seen it bigger than 500-600 MB. I don’t know if I had 100 000 pictures worth of thumbnails, but tens of thousands, definitely.

    2. Dave said on March 5, 2019 at 1:18 am
      Reply

      You can look in “C:\Users\Username\AppData\Local\Microsoft\Windows\Explorer”

      I’ve got over 15,000 media files that have thumbnails and the entire ‘Explorer’ folder in the path above is 795mb. I’m using the “large icons” size.

      For photos I use an old version of ACDSee. It does not store thumbnails so those are not included.

  3. AnorKnee Merce said on March 5, 2019 at 5:41 am
    Reply

    Do the automatic disk cleanup and disk defrag under Task Scheduler happen while the disk is still in use or running, eg while the users are still surfing the web.? If so, won’t this Automatic Maintenance feature cause program conflicts and computer problems.?

  4. ilev said on March 5, 2019 at 7:16 pm
    Reply

    Mine is “blocked” with the notice : “The Operator or Administrator has refused the request (0x800710E0)

    :-)

Leave a Reply

Check the box to consent to your data being stored in line with the guidelines set out in our privacy policy

Please note that your comment may not appear immediately after you post it.

Be polite: we do not allow comments that threaten or harass, or are personal attacks. Please leave politics and religion out of discussions!