> ## Documentation Index
> Fetch the complete documentation index at: https://kb.hosting.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Filtering unwanted e-mail (spam) in cPanel

> Discover how to filter spam from your email using cPanel with our step-by-step guide and explore related cPanel topics.

This article describes how to set up your e-mail account to filter messages marked as spam and automatically redirect them to a folder.

<Note>
  This article assumes that you have already enabled and configured Spam Filters. If you have not done so, please read [this article](/docs/unwanted-e-mail-spam) first.
</Note>

## Filtering unwanted e-mail (spam)

After you have enabled Spam Filters, it uses scores to mark suspicious messages as spam. You can have Spam Filters automatically delete these messages. However, in this scenario, you may occasionally lose legitimate messages that are mistakenly marked as spam (these are known as "false positives").

Alternatively, you can redirect all messages marked as spam into a separate folder in your account. You can check this folder periodically to see if any legitimate messages were mistakenly marked as spam.

If you use a third-party e-mail client application (such as Thunderbird or Outlook), you can set up this filtering directly on the client. However, you can accomplish the same effect by using e-mail filtering rules defined in cPanel. To do this, follow these steps:

1. Access your e-mail account using webmail or an e-mail client application.

2. Create a folder named **Spam**.
   > 📘 Note
   >
   > If you are using an e-mail client application, you may also need to subscribe to the *Spam* folder.

3. Log in to cPanel.
   > 📘 Note
   >
   > If you do not know how to log in to your cPanel account, please see [this article](/docs/accessing-cpanel).

4. On the **Tools** page, in the **Email** section, click **Email Filters**:\
   ![](https://static.hosting.com/kb/kb-cpanel-jupiter-email-email-filters-icon.png)

5. Locate the account for which you want to add a spam filter, and then click **Manage Filters**.

6. Click **Create a New Filter**.

7. In the **Filter Name** text box, type the filter name. For example, type `Spam Filter`.

8. Under **Rules**, specify the filter rules:

   * Change the value in the first list box from **From** to **Spam Status**.
     > 📘 Note
     >
     > If you cannot select the **Spam Status** option because it is gray, this means you have not enabled Spam Filters yet. You must enable Spam Filters first.

   * Change the value in the second list box from **contains** to **begins with**.

   * In the text box below the two list boxes, type `Yes`.

9. In the **Actions** list box, select **Deliver to Folder**.

10. Click **Browse**. A list of folders for the e-mail account appears.

11. Click the **Spam** folder.

12. Click **Create**. cPanel activates the filtering rule for the account, and messages marked as spam are now redirected to the *Spam* folder.

<Note>
  There are many other ways to define filter rules besides the rule described in steps 8 and 9 above. For example, you could define one filter that redirects messages with a score higher than 5 to your *Spam* folder, and another filter that deletes messages with a score higher than 8. To do this, use the **Spam Score** option instead of the **Spam Status** option.
</Note>

## Related articles

* [E-mail Filtering](/docs/e-mail-filtering)

* [Unwanted email (spam)](/docs/unwanted-e-mail-spam)

* [Preventing outgoing e-mail from being marked as spam](/docs/preventing-outgoing-e-mail-from-being-marked-as-spam)
