Innovate | Connect | Transform
ContactService statusUSD $

GICT knowledge base

Configure cPanel Webmail Filters with Clear Actions and Scope

Published

Email Client / Webmail

cPanel Webmail’s Email Filters process messages for the signed-in mailbox. They are distinct from cPanel Global Email Filters and from a mail application’s local rules. A misconfigured discard, redirect or stop action can hide valid mail, so start with narrow, reversible rules.

Create and test a mailbox filter

  1. Log in through the verified HTTPS Webmail service. Open the account/home settings and Email Filters; return from Roundcube to Webmail settings if needed.
  2. Choose Create a New Filter, give it a distinct descriptive name and check existing entries so you do not overwrite another rule.
  3. Select the message field, comparison and criteria. Prefer one simple justified condition before adding complex combinations.
  4. Choose an appropriate destination/action and save. Use the interface’s filter test with harmless synthetic message content, then review actual authorized delivery when appropriate.
  5. Inspect rule order and the saved configuration. A test of one sample is not proof that every legitimate message is unaffected.

Understand the matching fields

Fields include From, Subject, To, Reply Address, Body, Any Header, Any Recipient and List ID. They inspect different message information; a visible To header is not the complete recipient list, and the recipient normally cannot filter on a hidden BCC header. A sender string alone is not authenticated identity.

The delivery/error-state fields and Spam Status, Spam Bar and Spam Score have server-defined semantics. Use the installed help and actual scanner headers rather than treating every undeliverable notification as spam or inventing a score conversion. If scanning is absent, score-based rules may not behave as intended.

Text comparisons include equality, containment, beginning/ending tests and their negatives; regular expressions use pattern syntax rather than ordinary text. For multiple conditions, and requires all relevant conditions and or permits alternatives. Mixed expressions and rule order need explicit test cases. Body newlines can be normalized, so do not assume an escaped newline matches as in a local text editor.

Choose the action deliberately

Action Consequence
Deliver to Folder Delivers to the specified folder. Confirm the actual mailbox path rather than typing a guessed filesystem path.
Redirect to Email Routes to another address; the filter alone does not retain an inbox copy. Add the intended delivery action explicitly if both are required.
Discard Message Removes the message without a failure notice. Avoid this while investigating false positives.
Fail With Message Produces the configured failure behavior; it is not a private quarantine.
Stop Processing Rules Stops later processing for the matching message. It does not undo actions already performed.
Pipe to a Program Invokes an enabled server-side handler. Use only a reviewed application integration that treats all mail content as untrusted input.

Modify or remove safely

Record the previous rule, edit only the intended entry and retest both matching and ordinary mail. To delete, confirm the exact filter. Removing it cannot recover already discarded messages. Keep test samples and logs private, and do not disable global security or create a broad allow rule as a substitute for diagnosing a false positive.

References: cPanel field, operator and action semantics and Webmail filter lifecycle and testing.

Reviewed October 15, 2026. Documentation review only; no live filter, program pipe or customer message was changed or executed.

Related guides

Account services are unavailable until the production backend is configured.