See How to find the Windows 10 build number you are running. The policy is available starting in Windows 10 Build 18282. If you are running Windows 10 Pro, Enterprise, or Education edition, you can use the Local Group Policy Editor app to force disable or enable the Delete Temporary Files feature for all users. Disable Storage Sense to Delete Temporary Files with Local Group Policy You can download the following ready-to-use Registry files.įinally, you can use Local Group Policy.
To make the changes done by the Registry tweak take effect, you need to sign out and sign in to your user account. Set its value to 0 to disable the feature. Note: Even if you are running 64-bit Windows you must still create a 32-bit DWORD value. On the right, modify or create a new 32-Bit DWORD value 04. See how to go to a Registry key with one click. HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\StorageSense\Parameters\StoragePolicy Prevent Storage Sense from Deleting Temporary Files with a Registry Tweak You can re-enable the feature by turning on the check box Delete temporary files that my apps aren't using at any moment.Īlternatively, you can apply a Registry tweak to enable or disable this option. Turn off (uncheck) the option Delete temporary files that my apps aren't using. On the next page, navigate to the Temporary files section. On the right, click on the Configure Storage Sense or run it now link. Turn on the Storage sense option on the right. Here is how to disable or re-enable it.Ĭonfigure the policy option with a Registry tweak Disable Storage Sense to Delete Temporary Files in Windows 10 This feature is enabled by default in WIndows 10. While you can clear the %temp% folder manually (references: article #1, article #2, article #3), you can automate this process using Storage Sense. Storage Sense can be used to remove Windows upgrade log files, system-created Windows Error Reporting Files, Windows Defender Antivirus temporary files, Thumbnails, Temporary Internet Files, Device driver packages, DirectX Shader Cache, Downloaded Program Files, Delivery Optimization Files, old System log files, System error memory dump files and minidumps, temporary Windows update files, and more. The Storage Sense feature can be found in Settings, under System -> Storage. It allows you to maintain certain folders by preventing them from getting too large and clean them up automatically. Storage Sense is a nice, modern replacement for Disk Cleanup. When this option is enabled, Windows will delete them automatically and keep you drive clean besides saving your disk space. However, this does not happen often, so the system temporary directory or the app's temp directory continues to store them and fills your disk drive with junk.
Temporary files can be safely deleted after the process which has created them has quit. Temporary files are created by various Windows services, installed apps and tools.