You don't say which email system you use.
In Windows based emails it's all all in the Help section.
Here's the important bit -
Organize e‑mail using rules.
Here are answers to some common questions about organizing e‑mail by using rules in Windows Mail.
To create a rule
- <LI class=step>[IMG]mshelp://help/?id=Microsoft.Windows.Resources.ShellExecuteTopicIcon[/IMG] Click to open Windows Mail.
<LI class=step>Click the Tools menu, point to Message Rules, and then click Mail.
<LI class=step>In the New Mail Rule dialog box, under Select the Conditions for your rule, select one or more check boxes to set up the criteria that will be applied to incoming messages.
If you select multiple conditions, click the and hyperlink in the Rule Description section. In the And/Or dialog box, click Messages match all of the criteria or Messages match any of the criteria, and then click OK.
<LI class=step>Under Select the Actions for your rule, select one or more check boxes to determine how to handle messages that meet the conditions you selected.
- Click the underlined hyperlinks in the Rule Description section to specify the conditions or actions for your rule.
- Note
- You can click the contains people or contains specific words hyperlinks in the Rule Description box to specify the people or words you'd like Windows Mail to look for in messages. If you enter multiple people or multiple words per condition, you can use the Options button in the Select People or Type Specific Words dialog boxes to further customize your rule.
- In the Name of the rule box, select the default name, type a new name that describes your rule, and then click OK.