To use tags in Fava with Beancount, follow these steps:
1. Adding Tags in Beancount
- Include
#tagname
in your transaction entries:2023-10-01 * "Coffee Shop" #food Expenses:Coffee 20 USD Assets:Cash
- Multiple Tags: Add multiple tags separated by spaces:
2023-10-02 * "Business Trip" #travel #business Expenses:Travel 500 USD Liabilities:CreditCard
2. Viewing Tags in Fava
- Tags Tab: Navigate to the "Tags" section in Fava's sidebar to see all tags used.
- Transaction View: Tags appear as clickable links in individual transactions.
3. Filtering by Tags
- Click a Tag: Click any tag in a transaction or the Tags sidebar to filter all entries with that tag.
- Search Bar:
- Filter by tag:
tag:food
- Exclude a tag:
-tag:food
- Combine with other filters:
tag:food account:Expenses:Coffee
- Filter by tag:
4. Advanced Tag Usage
- Grouped Reports:
- In the Income/Expense Report, use the "Group by" dropdown and select "Tag".
- Custom Queries:
Use Fava's query interface (e.g.,SELECT * WHERE tag = 'food'
).
5. Managing Tags
- Rename/Delete: Edit your
.beancount
file directly (Fava doesn’t support in-app tag editing). - Tag Directives: Use
pushtag
/poptag
to apply tags to multiple transactions:pushtag #vacation 2023-07-15 * "Flight" #travel Expenses:Flights 300 USD Liabilities:CreditCard poptag
Example Workflow
- Tag Transactions: Add
#food
,#travel
, etc., to relevant transactions. - Analyze in Fava:
- Go to Tags > click
#travel
to see all travel expenses. - Use the Income/Expense Report grouped by tag to compare spending categories.
- Go to Tags > click
Key Notes
- Tags vs. Links: Tags (
#
) categorize transactions, while links (^
) connect related transactions. - Combining Filters: Use Fava’s search syntax (e.g.,
tag:business amount:>100
) for advanced filtering.
Tags enhance categorization and reporting, making it easier to track specific expenses or income streams in Fava.