How rules sort your transactions in Tally

Rules put each imported transaction into a category. Learn how first match wins, how contains, exact and regex work, and how remember this builds a rule.

Last updated · 5 min read

Rules decide which category a new transaction lands in. Tally checks them in order, lowest number first, and the first rule that is on and matches wins. There is no hidden scoring or AI. If a row has no matching rule, Tally copies the category you gave to an earlier transaction from the same merchant.

What is a rule?

A rule says “if the text of a transaction looks like this, give it that category”. For example: if the description contains LOBLAWS, categorize it as Groceries.

A rule has a few parts:

  • What to look for, the pattern.
  • Where to look: the description, the merchant, or either.
  • How to match: contains, exact or regex.
  • Which category to assign.
  • A priority number.
  • An on/off switch. Rules can be switched off without being deleted.

What does “first match wins” mean?

Tally goes through the rules from the lowest priority number to the highest. The first rule that matches the row is used, and the rest are ignored for that row. The Rules page says so directly: the first rule that is on and matches wins.

That has a practical effect. Put narrow rules at low numbers and broad rules at high numbers. Say you have a broad rule “contains SHELL” for Transport, and a narrow rule “contains SHELL CAFE” for Dining. If the broad rule runs first, the cafe is filed under Transport and the narrow rule never gets a turn. Give the narrow rule the lower number.

What are contains, exact and regex?

Contains matches if your pattern appears anywhere in the text. “TIM HORTONS” matches “TIM HORTONS #1234 TORONTO”. It is the one you will use most.

Exact matches only if the whole text equals your pattern. Use it for short, generic text where “contains” would catch too much. For example, an exact rule on “PAYMENT” will not catch “PAYMENT - THANK YOU”.

Regex is a pattern language for advanced matching. It lets one rule match several spellings, such as ROGERS|FIDO. Most people never need it. If a regex is wrong, it may match nothing, or too much, so test it on the Activity page afterwards.

What starter rules come with Tally?

There are 160 built in. 117 cover mostly Canadian merchants and bank wording: Loblaws, No Frills, Tim Hortons, Presto, Rogers, Petro-Canada, Cineplex, Air Canada and many more. 43 more are an add-on pack that includes Mexican and everyday merchants such as OXXO, Soriana, Telcel and Pemex.

Starter categories are Income, Groceries, Dining & Takeout, Housing & Rent, Utilities & Bills, Subscriptions, Transport, Shopping, Health, Entertainment, Travel, Fees & Charges and Transfers. You can add your own, pick a colour, and mark a category as counting as income or as excluded from totals.

Why is Transfers special?

Transfers is excluded from totals. Moving money between your own accounts is not spending, so it stays out of income and spending numbers.

What does “remember this” do?

When you change a transaction’s category, you can tick “remember this”. Tally creates a rule from that merchant, so the next import sorts it for you. The first few months involve a lot of this. After that, the “needs a category” list shrinks.

What if no rule matches?

Tally looks back at your history. If you have already categorized a transaction from the same merchant, it copies that category. This is “copy what you did last time”, not machine learning. You can always override it.

A simple routine

  1. Import the month. See how Tally catches duplicate transactions.
  2. Look at what is still uncategorized.
  3. For each merchant, set a category and tick “remember this”.
  4. Check the Rules page if something landed in the wrong place. Look for a broader rule with a lower number.

What goes wrong most often?

  • A broad rule runs too early. Lower the number on the narrow one, or switch the broad one off.
  • Text that changes each month. Bank descriptions often include store numbers or dates. Use “contains” on the stable part.
  • Two merchants with the same text. Use “exact” or a longer pattern.
  • Old categorizations. Rules apply to new rows. Changing a rule does not rewrite your history unless you choose to re-categorize.

Why this matters for your budget

Budgets, rollover and spending charts all rely on categories. Good rules mean you spend five minutes after an import, not thirty. Tally is in development and has no public sign-up, so this describes how it works today.

Sorted rows feed the budget

Categories drive budgets, rollover and spending totals.