Labels and filters in gmail: a short guide

Sometimes back I found myself searching for a partcular credit card's statement a few times. After a few times, I wanted to automate this, thus I found this hack; and hence sharing it here for me and to those who might need it.

  1. Create a Label:

    • To create a new label, choose one of these routes:
      • Route 1:
        • Click the "gear icon" (Settings) in the top right corner.
        • Select "See all settings."
        • Go to the "Labels" tab.
        • Scroll down and click "Create new label."
      • Route 2:
        • Click the "+" button in the "Labels" section of the sidebar.
    • Name your label, for example, "CC Statements."
    • Click "Create."

    You can also create nested labels. For instance:

    CC Statements

    • Amazon Pay
    • Makemytrip
    • Rupay

    To nest a label, select "Nest label under:" and choose the parent label.

  2. Create a Filter:

    • In Gmail's search bar, click the settings icon ("Show search options").

    • Set your criteria using the advanced search options. For example:

      • In the "Has the words" field, enter "ICICI Bank Credit Card Statement for the period" for the "CC Statements" label.
      • For the "Amazon Pay" label, enter "ICICI Bank Credit Card Statement for the period 4272XXXXXXXX7603."
    • Click the "Search" button. Review the results and adjust your search criteria as needed until you find all the emails you want to label.

    • Click "Create filter" to set up the filter.

    This filter will automatically apply the actions you choose to incoming emails based on the criteria you set.

  3. Complete the Filter Setup:

    • Click "Create filter."
    • Check "Apply the label" and select your label, like "CC Statements."
    • Optionally, check "Never send it to Spam."
    • If you want to apply the filter to existing emails, check "Also apply filter to matching conversations."
    • Click "Create filter."

Congratulations!

You've successfully created a new label. Now, any future emails that match your filter will automatically go into this label. As for me this makes it easy for me to find my credit card statements whenever I need them.