To filter IP addresses in cPanel email, you need to:
-
Log in to your cPanel account by following the guide in Accessing cPanel.
-
Open the filtering tool:
-
Choose the type of filter you want to create:
- To create a filter for a specific email account, click on "Email Filters" and then select the account you want to add a filter to.
- To create a global email filter, click on "Global Email Filters":
-
Click on "Create a New Filter".
-
In the "Filter Name" text box, enter a name for the filter.
-
Under "Rules", select "Any header" from the "From" list box.
-
In the "contains" list box, select "matches regex".
-
In the next text box, enter the regular expression for the specific IP address you want to filter. Replace "xxx" with the digits of the IP address. For example, if you want to filter the IP address 192.168.0.1, the regular expression would be "^192.168.0.1$". If you want to filter a range of IP addresses, you can use a regular expression like "^192.168.0.[0-9]{1,3}$".
-
Make sure the regular expression is not too broad to avoid unintentionally filtering messages you want to receive.
-
Under "Actions", select what to do with messages that match the filter, such as discarding the message, sending it to a specific folder, or redirecting it.
-
Click on "Create". The new filter will take effect immediately.
By following these steps, you can easily filter IP addresses in cPanel email and manage your incoming messages more effectively.