Advertisement

Encrypt Offline Files Cache in Windows 10

Offline Files is a special feature of Windows that allows you to access files stored on a network share locally, even when you are not connected to that network. It is possible to encrypt the contents of your Offline Files cache to protect it from unwanted access by other users and apps.

Advertisеment

Offline Files is a special feature of Windows that allows you to access files stored on a network share locally, even when you are not connected to that network. In modern Windows version, it includes a special "Always Offline" mode, that saves your bandwidth by syncing files between your PC and the appropriate network share periodically.

What is the Offline Files Feature

Offline Files makes network files available to a user, even if the network connection to the server is unavailable or slow. When working online, file access performance is at the speed of the network and server. When working offline, files are retrieved from the Offline Files folder at local access speeds. A computer switches to Offline Mode when:

  • Always Offline mode has been enabled
  • The server is unavailable
  • The network connection is slower than a configurable threshold
  • The user manually switches to Offline Mode by using the Work offline button in File Explorer

Note: The Offline Files feature is available

  • In Windows 7 in the Professional, Ultimate, and Enterprise editions.
  • In Windows 8 in the Pro and Enterprise editions.
  • In Windows 10 in the Pro, Enterprise, and Education editions.

Offline Files Cache

By default, Windows store Offline files for all users on the computer under the folder C:\Windows\CSC. It is a protected system folder. It contains cached files that were made available offline, and automatically cached files which were accessed by the user on a network share.

Windows deletes automatically cached files from the Offline Files cache on a least-recently used basis if the maximum cache size is reached. Files that were manually set as always available offline are never removed from the cache. To remove such files from the cache, you need to disable always offline mode for some of your network files, or remove the cache contents manually using the Sync Center in the classic Control Panel.

In order to restrict other users and apps from accessing your Offline Files cache, you can encrypt its contents. Also, it is possible to decrypt it if you change your mind.

To encrypt the Offline Files cache in Windows 10, do the following.

  1. Open the classic Control Panel app.
  2. Switch its view to either "Large icons" or "Small icons" as shown below.Control Panel Large Icons View
  3. Find the Sync Center icon.Windows 10 Sync Center Icon
  4. Open Sync Center and click on the link Manage offline files on the left.Windows 10 Manage Offline FIies Link
  5. In the next dialog, go to the Encryption tab.
  6. Click on the on the Encrypt button.Encrypt Offline Files Cache

You are done. If prompted, backup your your file encryption key. This will allow you to restore your file encryption key if you lose access to your encrypted Offline Files cache.Encrypt Offline Files Cache Backup Key

To decrypt the Offline Files cache later, open the Manage offline files dialog, navigate to the Encryption tab, and click on the Unencrypt button.Unencrypt Offline Files Cache

Alternatively, you can turn on or off the Offline Files cache encryption feature by applying a Registry tweak. Also, there is a Group Policy option to force enable or disable this feature.

Enable Offline Files Cache Encryption with a Registry Tweak

  1. Open the Registry Editor app.
  2. Go to the following Registry key.
    HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\NetCache

    See how to go to a Registry key with one click.

  3. On the right, modify or create a new 32-Bit DWORD value EncryptCache.
    Note: Even if you are running 64-bit Windows you must still create a 32-bit DWORD value.
    Set its value to 1 to enable the feature.Windows 10 Encrypt Offline Files Cache
  4. To make the changes done by the Registry tweak take effect, you need to sign out and sign in to your user account.

Note: A value data of 0 will disable the encryption feature.

You can download the following ready-to-use Registry files.

Download Registry Files

The undo tweak is included.

Enable Offline Files Cache Encryption using Local Group Policy

To restrict Access to Control Panel and Settings in Windows 10, do the following.

  1. Open Registry Editor.
  2. Go to the following Registry key:
    HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\NetCache

    Tip: See how to jump to the desired Registry key with one click.

    If you do not have such a key, then just create it.

  3. Here, create a new 32-bit DWORD value EncryptCache. Note: Even if you are running 64-bit Windows, you still need to use a 32-bit DWORD as the value type.
    Set it to 1 to force enable the Offline Files cache encryption feature.
  4. Restart Windows 10 to apply the restriction and you are done.

Later, you can delete the EncryptCache value to allow users enable or disable the Offline Files cache encryption manually.

To save your time, I made ready-to-use Registry files. You can download them here:

Download Registry Files

If you are running Windows 10 Pro, Enterprise, or Education edition, you can use the Local Group Policy Editor app to configure the options mentioned above with a GUI.

Using Local Group Policy Editor

  1. Press Win + R keys together on your keyboard and type:
    gpedit.msc

    Press Enter.Windows 10 run gpedit

  2. Group Policy Editor will open. Go to Computer Configuration\Administrative Templates\Network\Offline Files. Enable the policy option Encrypt the Offline Files cache.Windows 10 Encrypt Offline Files Cache GP
  3. Restart Windows 10.

That's it.

Related articles:

Support us

Winaero greatly relies on your support. You can help the site keep bringing you interesting and useful content and software by using these options:

If you like this article, please share it using the buttons below. It won't take a lot from you, but it will help us grow. Thanks for your support!

Advertisеment

Author: Sergey Tkachenko

Sergey Tkachenko is a software developer who started Winaero back in 2011. On this blog, Sergey is writing about everything connected to Microsoft, Windows and popular software. Follow him on Telegram, Twitter, and YouTube.

Leave a Reply

Your email address will not be published.

css.php
Using Telegram? Subscribe to the blog channel!
Hello. Add your message here.