Home
A document you open from Outlook, a browser or another app often lives in a temporary folder, and gets deleted later. SumatraPDF tells you when that’s the case and copies the file to a folder you keep, so your reading position, favorites and annotations don’t point at a file that’s gone.
Available in version 3.7 or later.
Most often you open an email attachment, then keep it with one click. At a glance:
  • Notification: opening a file from a temporary folder shows a notification at the bottom of the page
  • Copy to a permanent folder: the notification’s link, or Ctrl + K, then Copy Temporary File to Permanent Folder
  • Copy automatically: once you’ve picked a folder, every temporary file is copied there as it opens (TemporaryFileAutoMove)
  • Turn the notification off: close it with its ✕ (TemporaryFileShowNotification)

What counts as a temporary file #

  • a file in your temporary folder (%TEMP%, e.g. C:\Users\you\AppData\Local\Temp)
  • an Outlook attachment, a OneNote file or a file from the browser cache, which those apps put in their own temporary folders
  • SumatraPDF’s own copy of such a file: Outlook and OneNote need their file back, so SumatraPDF opens a copy of it

Copy a temporary file to a permanent folder #

  • Click Copy to a permanent folder in the notification.
  • Or press Ctrl + K and choose Copy Temporary File to Permanent Folder (CmdCopyTemporaryFileToNonTemporary). The command is listed only for a temporary file.
The first time, SumatraPDF asks which folder to use, starting in Downloads (or Documents). It remembers the folder in TemporaryFileDestDir and uses it from then on.
The file is copied under its own name and opened from the new location in the same tab. Its place in History and Frequently Read moves along, with the page you were on. The original stays where it was: the app that put it there may still need it.
  • If a different file of that name is already in the folder, the copy gets a number before the extension: report.1.pdf, report.2.pdf, …
  • If the same file (same size and content) is already there, nothing is copied: SumatraPDF opens the one that’s there.

Copy temporary files automatically #

Once TemporaryFileDestDir is set, a temporary file is copied there as it opens, and opened from the copy. That’s TemporaryFileAutoMove, on by default. Naming works as above, so opening the same attachment twice doesn’t make two copies. No notification is shown then.
To be asked each time instead, set TemporaryFileAutoMove = false.

Turn the notification off #

Close the notification with its ✕. That sets TemporaryFileShowNotification = false, and you won’t see it again. To bring it back, set it to true in Advanced settings.

Tips #

  • Use the notification’s link once to pick your folder; after that, attachments are kept automatically.
  • Point TemporaryFileDestDir at a folder you back up or sync, e.g. one in OneDrive.
  • To change the folder, edit TemporaryFileDestDir, or clear it to be asked again.
  • Annotations you save go to the copy, not to the attachment in the email.

Settings #

Setting Default What it does
TemporaryFileShowNotification true show the notification for a file from a temporary folder
TemporaryFileDestDir empty folder temporary files are copied to
TemporaryFileAutoMove true with TemporaryFileDestDir set, copy temporary files there when they open
TemporaryFileShowNotification = true
TemporaryFileDestDir = C:\Users\you\Documents\Attachments
TemporaryFileAutoMove = true

See also #