English
Complete instructions how to set the cache folder of Microsoft Edge to a RAM disk (on Windows)

Complete instructions how to set the cache folder of Microsoft Edge to a RAM disk (on Windows)

Incredients:

I. Settings instructions after October 2020
II. Old settings  

I. Settings for Edge above 85.0.xxx

Tip1:
 
There is a policy for changing the location of Edge’s cache:

Microsoft Edge Browser Policy Documentation| Microsoft Docs 

 

Add the policy manually to the registry:

Key:  Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Edge
Value: DiskCacheDir
Data type: REG_SZ
Data: , e.g. “D:\Edge Cache”

Tip2:

 Modify the the properties on the link to Microsoft Edge as such:

“C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe” –profile-directory=Default –disk-cache-dir=z:\MicrosoftEdgeCache

 

So Microsoft Edge now caches to z:\MicrosoftEdgeCache.

 Tip1 is recommended, because it can happen that you open Edge within a link of an Email for example and the settings would not be used.

II. Old Settings
*These steps are exactly as I did them (also works with ZuneMusic_8wekyb3d8bbwe if you stream a lot and don’t want it to wear/bloat your SSD – yes, “stream” apparently means “save to disk”), some steps may be unnecessary, but worth doing just in case. Your mileage my vary, if you follow these steps you do so at your own risk. Depending on restarts, step 1. may need to be repeated. MicrosoftEdge_8wekyb3d8bbwe may have a different name on your PC.

  1. Run cmd from the start menu with admin rights (right-click command prompt and select run as administrator).

Take full ownership of the cache folders to be safe, you may want to clear using disk cleanup first. Type 

takeown /F “%USERPROFILE%\AppData\Local\Packages\Microsoft.MicrosoftEdge_8wekyb3d8bbwe\AC” /A /R 

and press enter (%USERPROFILE% should work, but if not replace it with [Drive]:\Users\[Username] as per normal).

  1. When it finishes (depends on size) make an exact copy to your other drive (replace E:\Edge Cache as desired; and make sure Edge\Groove\etc. isn’t running or you will get ‘in use’ errors). Use:

    robocopy“%USERPROFILE%\AppData\Local\Packages\Microsoft.MicrosoftEdge_8wekyb3d8bbwe\AC” “E:\Edge Cache” /E /COPYALL /DCOPY:DAT

     ensure that there are no skipped\failed files, otherwise retry after disk cleanup.

  2. Instead of deleting the original as required for Symbolic Links, suggested you rename it:

    ren “%USERPROFILE%\AppData\Local\Packages\Microsoft.MicrosoftEdge_8wekyb3d8bbwe\AC” “AC Backup”

     in case the SymLink fails  when you can just rename it AC again, deleting the SymLink (you can do this using windows explorer as well). If the renaming encounters ‘in use’ errors even though Edge\Groove\etc. isn’t running then restart your PC and retry.

  3. Create the SymLink as follows (replacing E:\Edge Cache as needed):

    mklink /D “%USERPROFILE%\AppData\Local\Packages\Microsoft.MicrosoftEdge_8wekyb3d8bbwe\AC” “E:\Edge Cache”

    then restart your computer.

After some time if everything is working smoothly and you’re sure its the other drive being used for caching then you can safely delete the original AC Backup file, but I just deleted #!001\MicrosoftEdge\Cache from the backup. If you don’t use disk clean up, all your Edge cache should be retained.

Found on: Move the Edge browser cache to a RAM disk – Microsoft Community


1 thought on “Complete instructions how to set the cache folder of Microsoft Edge to a RAM disk (on Windows)

    • Author gravatar

      Correct title:
      “Complete instructions how to set the cache folder of Microsoft Edge to a RAM disk IN MICROSOFT WINDOWS”

Leave a Reply

Your email address will not be published. Required fields are marked *