Force Outlook To Delete Mails Completely

Martin Brinkmann
Feb 12, 2009
Updated • Nov 29, 2012
Email, Microsoft Outlook

If you are using the email client Microsoft Outlook you might have noticed that mails that you deleted earlier were still available in the Outlook pst files on the computer's hard drive. Those pst files can be opened with a special viewer for that file types or with a hex editor. When an email gets deleted in Microsoft Outlook it will only be removed from the program's interface but will stay in the associated pst file.

Only compressing the folders will delete that email permanently from the computer system. That's great if you deleted an email by accident and want to recover it but bad if an unauthorized third party tries to read your emails.

Microsoft Outlook provides the means to compress a folder immediately but no option to automate the task. It will however display a popup every 100th time that Outlook got closed asking if the user wants to compress the folders.

A far better solution to force Outlook to delete deleted mails completely at every shutdown is to change a setting in the Windows Registry.

Open the Windows Registry by pressing [Windows R], typing [regedit] and hitting [enter]. Navigate to the following Registry key:


The next step depends on the version of Microsoft Outlook or Microsoft Office that is installed on the computer. When in doubt perform the operation for all of the following subkeys.

Find the 9.0, 10.0, 11.0 or 12.0 keys in that folder. Click in the Outlook subkey and locate the key PST. If PST is not existing create it. A full Registry path to the right location could look like this:


Only the 12.0 can change in the path. If you are in the PST key right-click in the right pane and select New > DWord.

Name the Dword PSTNullFreeOnClose. Double-click it afterwards and give it the value 1 to enable it. This ensures that Microsoft Outlook will remove deleted mails completely on every exit from the computer system.


Tutorials & Tips

Previous Post: «
Next Post: «


  1. Charlie Spencer said on January 10, 2012 at 3:25 pm

    Be aware that this option / registry setting has been known to cause performance problems. It can cause Outlook to take an excessive amount of time to close. The application may continue running in the background as it processes the deletions. The amount of time the application continues is dependent on the size of the .PST or .OST files; the larger they are, the longer the app continues to run. It may take as much as an hour to finish closing completely, as monitored with Task Manager and in the system tray.

  2. Paul said on February 13, 2009 at 8:47 am

    Won’t that slow down the windows shutdown a *lot* if you have a pst file thats a gigabyte or so?

  3. Duncan said on February 13, 2009 at 8:39 am

    How would I do this running Vista 64-bit and office 2007

Leave a Reply

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

We love comments and welcome thoughtful and civilized discussion. Rudeness and personal attacks will not be tolerated. Please stay on-topic.
Please note that your comment may not appear immediately after you post it.