Outlook Cannot Create File Error: Fix Temp Folder Issue
In this article
Yes, you can fix Outlook’s “Cannot create file” error when opening attachments by clearing the temporary attachment folder and ensuring the folder has the correct permissions. The error appears because Outlook cannot write the attachment to its temp location, usually due to a corrupted file, insufficient space, or wrong access rights.
What You’ll Need
- Windows PC running Outlook 2016, 2019, or Microsoft 365
- Administrative privileges to modify folder permissions
- File Explorer access to the temporary attachment folder
- Outlook’s built‑in “Repair” feature or the Office Deployment Tool for a full reinstall if needed
- Optional: a backup of the current temp folder in case you need to restore files
Step‑by‑Step
- Locate the temporary attachment folder. The default path is
%LocalAppData%\Microsoft\Windows\Recent\Attachmentson Windows 10/11. Open File Explorer, paste the path into the address bar, and press Enter. If you’re using an older Outlook version, the folder may be%AppData%\Microsoft\Windows\Recent\Attachments. - Close Outlook completely. Exit the application from the system tray and ensure no background Outlook.exe processes remain in Task Manager.
- Delete the folder’s contents. Select all files and folders inside the Attachments directory and press Delete. If you prefer to keep a copy, copy the entire folder to another location before deleting.
- Verify folder permissions. Right‑click the Attachments folder, choose Properties, then the Security tab. Ensure the current user account has Full control and that Administrators also have full control. If not, click Edit, add the user, and grant full control.
- Check available disk space. The temp folder resides on the system drive (usually C:). Open This PC and confirm at least 200 MB of free space is available. If the drive is almost full, free up space by deleting temporary files or moving large items.
- Restart Outlook. Launch Outlook normally and attempt to open an attachment that previously triggered the error. The attachment should now download to the temp folder without issue.
- Disable problematic add‑ins (if error persists). Open Outlook, go to File > Options > Add‑Ins. At the bottom, next to Manage:, select COM Add‑Ins and click Go. Uncheck all add‑ins, click OK, and restart Outlook. If the error disappears, enable add‑ins one by one to identify the culprit.
- Update Outlook. Ensure the latest Office updates are installed. Open Outlook, go to File > Office Account > Update Options > Update Now. A recent patch may contain fixes for attachment handling.
- Reset the attachment handling settings. In Outlook, navigate to File > Options > Trust Center > Trust Center Settings > Attachment Handling. Click Default Attachment Location and set it to the default path. Also uncheck any option that removes personal information from attachments before sending.
- Recreate the temp folder if it was deleted. If the Attachments folder no longer exists, create a new folder at the same path and apply the same permissions as described earlier.
- Test with a new Outlook profile. If all else fails, create a fresh profile: Control Panel > Mail > Show Profiles > Add. Configure the new profile with your account and open Outlook. This isolates profile corruption as a potential cause.
Common Mistakes
- Leaving Outlook open while deleting the temp folder – the program locks the folder and prevents deletion.
- Deleting the wrong folder – the Attachments folder is distinct from the general
RecentorTempdirectories. - Not granting full control permissions – a read‑only or restricted account will trigger the error again.
- Assuming the error is due to the attachment file itself – many times the issue is the temp folder, not the attachment.
- Skipping the restart step – Outlook caches the temp folder path; a fresh launch is required for changes to take effect.
Tips
- Use
%temp%in the address bar to quickly access the system temp folder, then navigate toMicrosoft\Windows\Recent\Attachments. - Run Outlook in Safe Mode (Win + R, type
outlook.exe /safe) to confirm add‑ins aren’t the source of the problem. - Enable the Show hidden files option in File Explorer to ensure you see all subfolders.
- Back up the temp folder before deletion; sometimes the folder contains attachments you may need later.
- Use the Office Repair tool if the error persists after all other steps – this fixes corrupted program files.
Troubleshooting
If the error continues after clearing the temp folder:
- Check the Windows Event Viewer for any Outlook or system errors that mention file creation or access denied.
- Verify that an antivirus or security suite isn’t blocking Outlook’s write access to the temp folder. Temporarily disable the antivirus and test again.
- Confirm that the folder path hasn’t been changed in the registry. Open regedit, navigate to
HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Outlook\Preferences, and look for a value namedAttachTempFolder. If it exists, delete it to revert to the default. - Use the Office Deployment Tool to perform a per‑user repair, which restores default settings without affecting other Office applications.
- If the issue occurs only for a specific email account, try removing and re‑adding the account in Outlook.
- Check for disk errors: run
chkdsk /fon the system drive to fix file system corruption. - As a last resort, create a new Windows user profile and test Outlook there. A corrupted Windows profile can cause file access issues.
Frequently Asked Questions
Does this fix affect attachments from all senders?
Yes. Once the temp folder is cleared and permissions restored, Outlook can download attachments from any sender without encountering the “cannot create file” error.
Why does Outlook sometimes fail to create the temp file?
Common reasons include a full disk, corrupted temp folder, incorrect permissions, or interference from third‑party add‑ins or security software.
Can I change the location of the temporary attachment folder?
Outlook uses a fixed path that can’t be changed through the UI. You can modify the registry key AttachTempFolder to point to a different location, but this is advanced and may break updates.
Is it safe to delete all files in the temp folder?
Yes. The folder only stores temporary copies of attachments. Deleting its contents will not affect your mailbox or saved attachments.
What if I can’t delete files due to permissions?
Run File Explorer as an administrator or log in as a user with full control. If the folder is locked by Outlook, ensure the application is fully closed before attempting deletion.
Will this fix other attachment‑related issues, like corrupted downloads?
Clearing the temp folder and correcting permissions resolves most file‑creation errors, but corrupted attachments may still fail to open. In that case, request a new copy from the sender.