How can I clear the pagefile at shutdown?

A. As you will be aware the pagefile contains areas of memory that were swapped out to disk, it may be in a secure environment you want this pagefile cleared when the machine is shutdown as parts of memory containing passwords/sensitive information may have been mapped out to the pagefile.

  1. Start the registry editor (regedit.exe)
  2. Move to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management
  3. If the value ClearPageFileAtShutdown does not exist, from the Edit menu select New - DWORD value and enter a name of ClearPageFileAtShutdown
  4. Double click on ClearPageFileAtShutdown and set to 1
  5. Reboot the machine and next time you shutdown the pagefile will be cleared

Hide comments


  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.