Let’s assume that your network has multiple users, and each person uses Firefox as the default browser. If you do not want to keep their browsing data on your computer due to any reason. Therefore, instead of asking them to use a Private Window, you can set this setting in Registry Editor or Group Policy to get the job done automatically for all. Before you begin, you need to download and add Group Policy Template for Firefox.

Automatically delete All or Selected Firefox browsing data on exit using GPEDIT

To automatically delete all or selected Firefox browsing data when closes using Group Policy, follow these steps- Open the Local Group Policy Editor by pressing Win+R, typing gpedit.msc, and hitting the Enter button. Once it is opened, navigate to the following path- In the Firefox section, you can find a setting called Clear data when browser is closed. Double-click on this setting and choose the Enabled option.

Then, you can see some checkboxes. The options are:

CacheCookiesDownload HistoryForm Search HistoryActive LoginsSite PreferencesOffline Website Data.

Make a tick in every corresponding checkbox that you want to clear. For instance, if you want to delete only Cache and Cookies, tick those two checkboxes. Similarly, if you’re going to clear everything when Firefox closes, tick all the checkboxes.

At last, click the OK button. You can set it up using Registry Editor also. If you follow the following method, don’t forget to backup your Registry files before changing any value.

Auto-delete Firefox browsing data on exit using REGEDIT

To auto-delete Firefox browsing data on exit using Registry, follow these steps- Let’s check out these steps in detail to know more. To get started, open the Registry Editor by pressing Win+R, typing regedit, hitting the Enter button, and selecting the Yes option. Then, navigate the following path- Right-click on the Policies key, select New > Key and set the name as Mozilla. Then, right-click on Mozilla > New > Key, and name it as Firefox.

Following that, right-click on the Firefox key, choose New > Key and name it as SanitizeOnShutdown.

Now, right-click on SanitizeOnShutdown, select New > DWORD (32-bit) Value, and name it as Cache. In other terms, you have to name this REG_DWORD value as per the data you want to clear. In case you want to clear only cache, call it ­Cache. Otherwise, you can use the following names as per your requirements-

CacheCookiesDownloadsFormDataHistoryOfflineAppsSessionsSiteSettings

After creating the REG_DWORD value, you have to change the Value data to 1. For that, double-click on the REG_DWORD value, enter 1 as the Value data and click the OK button. That’s all! Hope it helps.