In this tutorial, I will show you how to setup email filter in cPanel.
Using the Email Filter in the cPanel, you can efficiently manage your emails, having control over the type of email that you have. This can be very helpful in dealing with spam emails.
Let’s get started.
READ MORE: How To Track Email Delivery On cPanel
How To Setup Email Filter In cPanel
In the cPanel, there are two levels of email filtering interfaces: Global Email Filters and User-Level Email Filters. The same settings can be applied to both of them, though the Global Filters affect all email addresses that are under that domain.
- Log into your cPanel and go to the Email section.
- In the Email section, select Email Filter.
- On the Email Filter page, go to the Filters by Users section.
- Scroll down to the email address that you want to filter and click Manage Filters.
- In the Edit Filters for email address page, click on Create a New Filter.
- On the next screen, set a unique name for the Filter Name.
- Next, go to the Rules section to set up and review the rules and criteria you want to use for the email filter.
- From: the message sender’s email address
- Subject: the subject of the email
- To: the email address of the message recipient
- Reply Address: the address at which the sender will receive replies
- Body: the content of the message
- Any Header: any part of the message’s header
- Any recipient: any recipient of the message
- Has not been previously delivered: The system will only examine messages in the queue for delivery.
- Is an Error Message: The system only examines error messages that an auto-response system sends.
- List ID: the account’s mailing lists
- Spam Status: whether Apache SpamAssassin™ marked the message as spam. The Spam Status line begins with Yes or No.
- Spam Bar: the content of the Spam Bar header that Apache SpamAssassin generated for this message. The more plus signs (+) that Apache SpamAssassin assigns to a message, the greater the likelihood that the system marks the message as spam.
- Spam Score: the total number of plus signs (+) in the Spam Bar value, expressed as an integer.
Below are the comparison operators between the email and the criteria that you set:
- equals: The message matches exactly with the defined string.
- matches regrex: The message matches the regular expression that you define.
- contains: The message has a string that you define.
- does not contain: the message doesn’t contain the defined string
- begins with: the message starts with the defined string
- ends with: the message ends with the defined string
- does not begin: The message does not begin with the defined string.
- does not end with: The message does not end with the defined string.
- does not match: The message does not exactly match the defined string.
- Enter the word or phrase you want to filter below the operator and criteria fields.
- Set the Action that you want to occur when the incoming email matches the rule in your email filter.
- Discard Message: the message will be discarded without any failure message sent to the sender.
- Redirect to Email: the message will be forwarded to a specific email address.
- Fail With Message: the system will discard the message, and the sender will automatically receive a failure notice.
- Stop Processing rules: the system will ignore and stop applying all other filter rules to the message.
- Deliver to Folder: the message will be delivered to a specific folder.
- Pipe to a Program: the system will send the incoming message to a particular program for processing.
- When you are done setting all the rules for the email filtering, click Create.
You have now successfully setup email filter in cPanel. If you have any questions, please leave them in the comment section. I will be so happy to hear from you.
[…] READ MORE: How To Setup Email Filter In cPanel […]