How to make outlook junk mail folder delete automatically
Outlook's Junk Email Filter is designed to automatically move suspected spam emails to the Junk Email folder. However, it doesn't have a built-in feature to automatically delete emails in the Junk Email folder. But, you can set up a rule to delete emails in the Junk Email folder periodically. Here's how:
Method 1: Using Outlook's built-in rule
- Open Outlook and go to the "Home" tab in the ribbon.
- Click on the "Rules" button in the "Move" group.
- Click on "Manage Rules & Alerts" in the drop-down menu.
- Click on "New Rule" and select "Start from a blank rule".
- Choose "Move messages from someone to a folder" and click "Next".
- In the "Step 1: Select actions" window, select "Move it to the specified folder" and choose the "Junk Email" folder.
- Click "Next" and then "Finish".
- Name the rule (e.g., "Delete Junk Email") and click "OK".
Method 2: Using VBA script
-
Open Outlook's Visual Basic Editor by pressing "Alt + F11" or by navigating to "Developer" tab in the ribbon and clicking on "Visual Basic".
-
In the Visual Basic Editor, click on "Insert" > "Module" to insert a new module.
-
Paste the following code into the module:
Sub DeleteJunkEmail() Dim olApp As Outlook.Application Dim olNamespace As Outlook.Namespace Dim olFolder As MAPIFolder Dim olItems As Items Set olApp = Outlook.Application Set olNamespace = olApp.GetNamespace("MAPI") Set olFolder = olNamespace.GetDefaultFolder(olFolderInbox).Folders("Junk Email") Set olItems = olFolder.Items For Each olItem In olItems If olItem.Class = olMail Then olItem.Delete End If Next olItem Set olItems = Nothing Set olFolder = Nothing Set olNamespace = Nothing Set olApp = Nothing End Sub
-
Save the module by clicking "File" > "Save" (or press "Ctrl + S").
-
To run the script, go to "Developer" tab in the ribbon and click on "Macros" > "Run" > "DeleteJunkEmail".
Method 3: Using a third-party add-in
There are several third-party add-ins available that can help you automate the deletion of emails in the Junk Email folder. Some popular options include:
- SaneBlackHole: A free add-in that can automatically delete emails in the Junk Email folder.
- Junk Mail Cleaner: A paid add-in that can clean up your Junk Email folder and delete unwanted emails.
Please note that before using any of these methods, make sure to review the contents of your Junk Email folder regularly to ensure that legitimate emails are not being deleted accidentally.