Set Up Spam Filter for cPanel Email
Setting up a spam filter helps manage incoming emails by identifying and handling messages that may be considered unsolicited or unwanted. Email hosting typically uses filtering tools to scan incoming messages based on specific criteria such as sender details, content, and message structure.
This article provides instructions on how to set up a spam filter for your email hosting and configure available options for handling flagged messages.
What Is Spam Filter?
Our hosting service uses SpamAssassin, which is the world's #1 Open Source anti-spam platform, to filter, classify, and block spam email.
To efficiently filter Spam, SpamAssassin scans the following parts of every incoming email:
- Header
- Text or Main Message
- HTML Coding
- Domain
- Sender’s IP Address
How To Enable SpamAssassin in Email Hosting
SpamAssassin is enabled by default. If it's not, follow the steps below to turn it on:
- Log in to your email hosting cPanel.
- Under the Email section, click Spam Filters.
- Turn on the toggle for Process New Emails and Mark them as Spam.
- A confirmation message will appear: "Apache SpamAssassin has been enabled."

How To Route Spam Emails to the Junk Folder
By default, all emails—including those marked as spam—go directly to your inbox.
To automatically move spam emails to your Junk folder, you’ll need to enable SpamAssassin and create a Global Email Filter in your Hosting Manager.
Follow the steps below to set it up:
- Log in to your email hosting cPanel.
- Under the Email section, click Global Email Filters.
- Click Create a New Filter.
- Under Filter Name, enter a unique name that describes your filter — for example: Move Spam Emails to Junk Folder.
- Under Rules:
- In the first dropdown, select Spam Status
- In the second dropdown, select begins with
- In the box provided, type Yes
- Under Actions:
- Select Deliver to Folder
- Click Browse, then select the Junk folder
-
Click Create.
A confirmation message will appear at the top of the page once your filter has been successfully applied.
How To Enable the SpamAssassin Auto-Delete Function
SpamAssassin uses a scoring system to detect spam emails.
You can customize this scoring threshold to automatically delete unwanted emails instead of storing them in your Junk folder. This helps keep your mailbox clean by preventing spam from being saved altogether.
To enable the Auto-Delete function, follow the steps below:
- Log in to your email hosting cPanel.
- Under the Email section, click Spam Filters.
- Turn on the toggle for Automatically Delete New Spam (Auto-Delete):

- To adjust which spam emails get deleted, click Configure Auto-Delete Settings and set your preferred spam score threshold.