cPanel® Blog

How to Create a Spam Filter

Let’s be honest, no one likes spam; not hosting providers, not web users, and certainly not us. That’s why it has become a reccurring subject on the cPanel Blog. Using one of our favorite features, Apache SpamAssassin, we want to equip you, the cPanel user, with a nifty trick to keep spam out of your inbox.

Apache SpamAssassin™

Preloaded into the cPanel dashboard, Apache SpamAssassin is an open-source tool built to filter and classify emails while blocking spam. Through a combination of subject line and body text analysis, Bayesian filtering, and DNS blacklists, SpamAssassin drastically limits and can prevent spam from touching your inbox.

Creating a Spam Filter

In the Email section of your cPanel account, choose Apache SpamAssassin. (If your hosting provider hasn’t already enabled this feature, select Apache SpamAssassin and then switch it on.)

Now you’re ready to set up email filters and specify how powerfully you’d like SpamAssassin to gate and vet incoming messages. Here’s how:

  1. Head to the “cPanel Email” section, navigate to “Global Email Filters,” and select “Create New Filter.”
  2. Select “Spam Bar” from the first menu in the “Rules” section and then choose “Contains” from the second menu in that same section.
  3. In that field, enter a spam score using a series of (+) symbols, with 5 being an adequate number for an individual user. Select “Deliver to folder” from the “Actions” section and enter the name of the folder to which you would like to direct spam.
  4. Click “Create” to activate the spam filter and, voila, your first filter is set up! (Be sure to check to occasionally check this folder to ensure items that are NOT spam aren’t being flagged.)

This article was originally posted on Jan 19, 2016, and has been updated for technical accuracy. 


Follow the links to learn more about creating spam filters or Apache SpamAssassin.

JR

Equal parts prose, positivity, and passion, JR Miller is a web writer that likes using words to connect with people, enhance experiences, and solve problems. Approaching copywriting as both an art and a science, he believes that a good impression is one that stays with you after the browser window has closed.

2 responses to “How to Create a Spam Filter”

  1. Chintu Seo says:

    nice article Sasta Host offer Cheapest Web Hosting Service in India Since 2009

  2. This is a nice how-to. You can also create a spam box in the SpamAssasin page much easier by just clicking “Enable Spam Box” and it creates the filter/folder automatically.

Leave a Reply