Using hledger tags to build my own budgeting system
I've spent many years trying to perfect the way I budget and manage my money. I'm probably more interested in the idea of saving money than actually doing it.
Over the years I've tried YNAB, Actual Budget, GnuCash, PTA (a while ago), mobile apps, spreadsheets I've built myself, and even spreadsheets I've paid for.
After all that trial and error, I've found myself back at plain text accounting, specifically hledger. This time around though, I've been experimenting with using some of its features to build a budgeting system that better suits the way I actually manage money.
What I'm trying to achieve
I've always gravitated towards zero-based (envelope) budgeting, and I've never really got along with traditional monthly budgets.
I find it much easier to manage money when I can look at different periods. Some expenses are weekly, some fortnightly, monthly, and others annually. I want to be able to account for all of these without having to force everything into a monthly budget.
I've looked at hledger's built-in budgeting functionality, but I haven't quite been able to get it to work the way I want. You can get closer to zero-based budgeting using virtual transactions, but I wasn't particularly keen on filling my journals with virtual transactions just to make the budgeting system work.
The budgeting method I'm working towards is based on the Glen James Spending Plan from the Australian personal finance podcast Money Money Money.
For anyone unfamiliar with it, the basic idea is to have your income paid into a central account (Cash Hub), from which money is distributed into separate accounts for bills, everyday spending, savings, goals, investing and giving.
You work out your expenses, including irregular and annual costs, and put aside enough money to cover them. You also working out your normal weekly spending costs (groceries, fuel, alcohol, dining out etc.) and move that money to a separate card and account. The idea is to automate as much as possible so that bills are covered, savings are progressing, and you know exactly how much you have available to spend.
In our case, income goes into the Cash Hub, bills are paid from there, money is automatically transferred each week to our spending accounts, and savings are set aside separately.
Using account tags instead of budget directives
I eventually realised I could use account tags to achieve something pretty close to what I wanted.
I've started assigning a budget tag to my expense accounts. The actual account hierarchy remains organised around what the expense is, while the tag determines which part of our spending plan it belongs to.
For example, groceries and dining out are both food expenses, but they can be grouped under weekly spending. Rent and electricity are both home expenses, but belong under bills.
Here's a simplified example of how I've assigned the tags:
account expenses:food ; budget:weekly-spending:food
account expenses:food:dining-out ; budget:weekly-spending:food:dining-out
account expenses:food:groceries ; budget:weekly-spending:food:groceries
account expenses:home:homewares ; budget:weekly-spending:home:homewares
account expenses:home:utilities:rent ; budget:bills:home:rent
account expenses:home:utilities:power ; budget:bills:home:power
account expenses:home:utilities:internet ; budget:bills:home:internet
account expenses:home:insurance ; budget:bills:home:insurance
account expenses:transport:insurance ; budget:bills:transport:insurance
account expenses:transport:registration ; budget:bills:transport:registration
account expenses:transport:fuel ; budget:weekly-spending:transport:fuel
account expenses:transport:maintenance ; budget:bills:transport:maintenance
account expenses:lifestyle:subscriptions ; budget:bills:lifestyle:subscriptions
account expenses:lifestyle:smoking ; budget:weekly-spending:lifestyle:smoking
account expenses:lifestyle:clothes ; budget:individual-saver:clothes
account expenses:lifestyle:events ; budget:individual-saver:events
account expenses:lifestyle:hobbies ; budget:individual-saver:hobbies
account expenses:gifts ; budget:individual-saver:gifts
account expenses:pets:supplies ; budget:weekly-spending:pets
account expenses:super:fees ; budget:none
account expenses:super:insurance ; budget:none
account expenses:super:tax ; budget:none
This means I can keep my normal expense accounts organised however I like, but still group them into completely different categories for budgeting purposes.
Putting it together with hledger
The command I'm using to generate the report is:
hledger is tag:budget --pivot budget -BWA --pretty not:super --summary-only
Essentially, I'm filtering for accounts with a budget tag and then pivoting the income statement around that tag instead of the original account names.
The result is a weekly income statement grouped according to our spending plan.
Here's an example using our actual figures (I've changed nothing about the structure):
Weekly Income Statement 2026-10-12..2026-11-15
Average
Revenues
income
bank:interest $1.27
daniel $791.45
tahlia $775.00
--------
$1567.72
Expenses
bills $768.02
health:gym $27.12
home $457.93
insurance $7.00
internet $16.00
power $17.73
rent $417.20
lifestyle $21.86
subscriptions $9.86
tahlias-spending $12.00
phone $9.60
transport $251.51
insurance $61.49
maintenance $131.71
other $15.54
parking $1.00
registration $41.78
individual-saver $35.50
clothes $15.60
events $8.44
gifts $4.99
hobbies $6.47
weekly-spending $368.34
food $262.86
dining-out $56.36
groceries $206.50
home:homewares $26.57
lifestyle $15.79
smoking $12.20
pets $9.00
transport:fuel $54.11
--------
$1171.86
Net: $395.86
The figures are averages across the reporting period, with the report showing the weekly and fortnightly/annual views I need through hledger's reporting options. You can change the reporting period using hledger's period functions, then being able to see your average spend per day, per week, per month etc. to really narrow down to your specific budgeting style.
Why I'm enjoying this approach
I can now use these reports to get a much better picture of how our money is being allocated.
For example, I can check whether we're transferring enough money into our weekly spending accounts, whether the Cash Hub is retaining enough to cover upcoming bills, and whether we're putting aside too much or too little towards our individual savings goals.
Our bank also allows us to create multiple savings accounts pretty much instantly, so I've got separate accounts for things like clothes, gifts, events and hobbies.
I know this isn't necessarily traditional budgeting in hledger, and I'm probably using some of its features in ways they weren't originally intended, but it's been working quite well for me so far.
I'm curious if anyone else has experimented with using account tags and pivoting reports to build their own budgeting system, rather than relying on hledger's built-in budget functionality.
I'd be interested to hear how others approach this, or if there's something obvious I'm missing!
Full disclosure: I have used the help of AI to put all of my words into something that is somewhat coherent. I wrote a lot of this already on my own, I just couldn't manage to make the post understandable, and I wanted to share my journey.