Filters allow you to control what happens when specific messages are received in your Inbox. You could set a filter to label all messages from a certain person, for example, or to star all messages containing key words in their subject.
To create a filter:
Click on the Search Options button at the end of the Search box along the top of the mail screen
First, choose the condition that the message must meet in order for the filter to be applied. If you want to act on all messages from a specific sender, for example, enter their email address in the From box. If you want to act on all messages containing a specific phrase, enter this in the Includes the words box
If you want the filter to apply to a number of email addresses, enter these in the From box, typing OR between each email address.
Click on the Create filter with this search button to continue
Now choose the action you wish to carry out on all messages that match the condition specified in the previous step e.g. apply a specific label, or star the message
If you want to carry out the action on any messages already received, check the box to Also apply filter to matching conversations
Click on Create Filter when complete
All filters can be listed by clicking on the Settings cog, choosing See all Settings then clicking on Filters. From this screen you can edit a filter or delete it so that it no longer runs on messages you receive.