In Beancount, tags are plain-text labels used to filter, group, and categorize transactions without changing your account structure. [1, 2, 3, 4, 5]
https://beancount.io/docs/introduction-to-beancount#organizing-with-tags--and-links-
Here is how to use them effectively.
Syntax and Usage
You can add tags to transactions using the # symbol. They must appear on the main transaction line, after the narration. [6]
2026-06-21 * "Target" "Bought kitchen supplies" #home #shopping
Expenses:Home:Supplies 45.00 USD
Assets:Checking:BofA -45.00 USD
Key Rules
- No spaces: Tags cannot contain spaces (e.g., use #vacation-2026, not #vacation 2026).
- Placement: They belong on the entry line, not on individual posting lines.
- Case-sensitive: Beancount treats #Tax and #tax as different tags. [7, 8]
Tagging Multiple Transactions (Block Tags) [9]
If you have many consecutive transactions that share the same tag, you can open and close a tag block using pushtag and poptag.
pushtag #trip-japan-2026
2026-04-12 * "Delta Air Lines" "Flight to Tokyo"
Expenses:Travel:Flights 800.00 USD
Assets:CreditCard -800.00 USD
2026-04-13 * "Tokyo Hotel" "Deposit"
Expenses:Travel:Lodging 200.00 USD
Assets:CreditCard -200.00 USD
poptag #trip-japan-2026
Common Use Cases
- Trips and Events: Track all expenses for a specific vacation or wedding.
- Tax Reporting: Label deductible expenses with #tax-2026 or #deductible.
- Shared Expenses: Mark items to split with roommates or a partner using #split.
- Projects: Track freelance business expenses per client (e.g., #client-acme). [10, 11]
Querying Tags
You can filter your data by tags in Beancount's SQL query tool or inside the Fava web interface. [12, 13]
SELECT date, account, position WHERE has_tag(tags, 'home')
To help optimize your ledger, let me know:
- Are you trying to track a specific type of event (like a trip or business expense)?
- Do you need help querying or filtering these tags in Fava?
- Would you like to see how tags compare to links (^) or metadata?
[1] [https://github.com](https://github.com/beancount/ledger2beancount/blob/master/docs/guide.md)
[2] [https://developer.harness.io](https://developer.harness.io/docs/database-devops/concepts/glossary/tag)
[3] [https://beancount.io](https://beancount.io/docs/community-showcase)
[4] [https://beancount.io](https://beancount.io/docs/introduction-to-beancount)
[5] [https://cheat.readthedocs.io](https://cheat.readthedocs.io/en/latest/beancount.html)
[6] [https://goodbudget.com](https://goodbudget.com/help/customize-your-goodbudget/tags/)
[7] [https://industrialmonitordirect.com](https://industrialmonitordirect.com/blogs/knowledgebase/converting-factorytalk-tags-to-wonderware-intouch-import-format)
[8] [https://github.com](https://github.com/beancount/ledger2beancount/blob/master/docs/guide.md)
[9] [https://parseport.com](https://parseport.com/esef/block-tagging/)
[10] [https://beancount.io](https://beancount.io/docs/industry-specific-setups)
[11] [https://beancount.io](https://beancount.io/blog/2025/09/04/detox-your-small-business-finances)
[12] [https://beancount.io](https://beancount.io/blog/2025/04/15/beancount-ecosystem)
[13] [https://pypi.org](https://pypi.org/project/beancount/)
In Beancount, tags are plain-text labels used to filter, group, and categorize transactions without changing your account structure. [1, 2, 3, 4, 5]
https://beancount.io/docs/introduction-to-beancount#organizing-with-tags--and-links-
Here is how to use them effectively.
Syntax and Usage
You can add tags to transactions using the # symbol. They must appear on the main transaction line, after the narration. [6]
2026-06-21 * "Target" "Bought kitchen supplies" #home #shopping
Expenses:Home:Supplies 45.00 USD
Assets:Checking:BofA -45.00 USD
Key Rules
Tagging Multiple Transactions (Block Tags) [9]
If you have many consecutive transactions that share the same tag, you can open and close a tag block using pushtag and poptag.
pushtag #trip-japan-2026
2026-04-12 * "Delta Air Lines" "Flight to Tokyo"
Expenses:Travel:Flights 800.00 USD
Assets:CreditCard -800.00 USD
2026-04-13 * "Tokyo Hotel" "Deposit"
Expenses:Travel:Lodging 200.00 USD
Assets:CreditCard -200.00 USD
poptag #trip-japan-2026
Common Use Cases
Querying Tags
You can filter your data by tags in Beancount's SQL query tool or inside the Fava web interface. [12, 13]
SELECT date, account, position WHERE has_tag(tags, 'home')
To help optimize your ledger, let me know:
[1] [https://github.com](https://github.com/beancount/ledger2beancount/blob/master/docs/guide.md)
[2] [https://developer.harness.io](https://developer.harness.io/docs/database-devops/concepts/glossary/tag)
[3] [https://beancount.io](https://beancount.io/docs/community-showcase)
[4] [https://beancount.io](https://beancount.io/docs/introduction-to-beancount)
[5] [https://cheat.readthedocs.io](https://cheat.readthedocs.io/en/latest/beancount.html)
[6] [https://goodbudget.com](https://goodbudget.com/help/customize-your-goodbudget/tags/)
[7] [https://industrialmonitordirect.com](https://industrialmonitordirect.com/blogs/knowledgebase/converting-factorytalk-tags-to-wonderware-intouch-import-format)
[8] [https://github.com](https://github.com/beancount/ledger2beancount/blob/master/docs/guide.md)
[9] [https://parseport.com](https://parseport.com/esef/block-tagging/)
[10] [https://beancount.io](https://beancount.io/docs/industry-specific-setups)
[11] [https://beancount.io](https://beancount.io/blog/2025/09/04/detox-your-small-business-finances)
[12] [https://beancount.io](https://beancount.io/blog/2025/04/15/beancount-ecosystem)
[13] [https://pypi.org](https://pypi.org/project/beancount/)