Welcome to the Plain Text Ledger! I’m Yichu Zhou, a machine learning scientist exploring ways to manage personal finances more efficiently. On this site, I’ll share my journey and insights into plain text accounting using Beancount—an easy-to-understand, tech-friendly method of tracking finances using simple text files and version control. Plain text accounting is an alternative to traditional software, offering transparency and flexibility. Join me as I dive into this innovative approach and share what I learn along the way.
Recording Self-Submitted Insurance Claims: Why the Original Purchase Is the Part You Can Skip
Here’s a scene from my ledger that happens a few times a year. Over the course of a month, we buy a scattered pile of medical things out of pocket — a doctor’s visit copay, a box of prescribed supplies from the pharmacy, some physical-therapy sessions, a couple of online orders for a brace and a monitor. Nothing gets billed to insurance automatically, because these are the kinds of items you have to submit yourself. So I collect the receipts, fill out the insurer’s claim form, and mail off a bundle totaling something like 260 USD. Weeks later, an Explanation of Benefits shows up. The insurer has approved 138.01 USD — not the full 260 USD — and a check for that amount is on the way. And now I have two small, annoying problems. The first is reconciliation at the item level. The EOB doesn’t say “we reimbursed the brace and the copay but not the pharmacy order.” It shows adjusted, bundled, partially-approved line amounts that don’t map cleanly onto the charges as they hit my credit card. Figuring out which of the eight things I bought actually got covered — and which got denied — is genuinely tedious, and most of the time I don’t actually need the answer. The second problem is worse. That pharmacy charge from six weeks ago? It got imported and auto-categorized as groceries, because the store that filled the prescription also sells groceries and my importer keyed off the merchant name. By the time the check arrives, the original purchase has scattered into three or four categories, half of them wrong, and hunting it down is its own small archaeology project. This post is about how I book the reimbursement anyway — cleanly, in a couple of minutes — without solving either of those problems. ...
Recording Big-Ticket Purchases in Beancount: Asset or Expense?
You sign for a new car, and 30,000 USD leaves your checking account in a single transfer to the dealer. That night you open Beancount to record it, and the entry stalls on what feels less like data entry than a type error. Expense it, and Expenses absorbs 30,000 USD in one month — the income statement now reports that you torched a year’s discretionary budget, when in fact a car worth nearly that much is sitting in the driveway. Capitalize it as an asset instead, and net worth jumps by the sticker price of something that began depreciating the instant it left the lot; leave that number frozen and, three years on, the balance sheet still asserts the car is worth exactly what you paid, long after it’s really worth closer to 15,000 USD. Neither entry reconciles with reality. That mismatch — a value that won’t sit cleanly in either bucket — is the signal worth debugging: the categories aren’t broken, they’re being applied to the wrong kind of thing. ...
Recording Taxes in Beancount
Introduction Tax accounting is one of the most crucial aspects of personal and business bookkeeping, yet it can be intimidating for newcomers to double-entry accounting systems like Beancount. This guide will walk you through the fundamental concepts and practical techniques for accurately recording various types of taxes in your Beancount ledger. ...
Beancount RSU
Introduction Restricted Stock Units (RSUs) are a common part of compensation packages in tech and other industries. They can represent a significant portion of your income—but they also introduce complexity to your personal finances. RSUs vest over time, are subject to income taxes when they vest, and may later be sold, triggering capital gains. If you’re already using Beancount to track your finances, it’s worth bringing your RSUs into the ledger. In this post, we’ll walk through how to record RSUs in Beancount in a way that keeps your records clean, auditable, and tax-ready. ...
Trading Stocks using Beancount
Introduction Tracking your investments can easily become a mess of PDFs, spreadsheets, and inconsistent brokerage exports. If you’re already using Beancount to manage your personal finances, why not bring that same clarity and precision to your stock portfolio? Beancount isn’t just for daily finances—it’s a powerful tool for investment tracking. With its plain-text syntax and double-entry model, it gives you full control over cost basis, dividends, capital gains, and multi-currency holdings—without relying on a brokerage interface. It can easily become a central management tool for your investments. ...
Tracking U.S. Health Expenses with Beancount
Accounting for health-related expenses in the U.S. is slightly different from typical expense tracking because it usually involves insurance. In this post, we’ll walk through how to use Beancount to track your healthcare expenses in the U.S. How Healthcare System Work in US How healthcare system works In its simplest form, the healthcare system typically works as follows: You visit a healthcare provider who delivers medical services to you. The provider submits claims to your insurance company. The insurance company verifies the claims and pays a portion (or all, depending on your coverage). Once the claims are processed, the healthcare provider sends you a bill for the remaining amount. The insurance company also sends you an Explanation of Benefits (EOB), detailing how your medical claims were processed based on your plan. As a patient, there are two important documents you should pay attention to: ...
Principles of Building Chart of Accounts in Beancount
One of the first steps to mastering Beancount is designing a clean, flexible, and future-proof Chart of Accounts (CoA). This structure defines how you categorize your financial life—and ultimately, how useful and insightful your reports will be. In this post, I’ll walk through the principles, pitfalls, and patterns I’ve learned while building my own CoA in Beancount. Principles I have been using Beancount for a few years. Over these years, I changed the CoA many times. I found that the following three high level principles can be a good starting point for designing your accounts structure: ...
Tracking Retirement Accounts in Beancount
Introduction In the United States, retirement accounts are specialized investment vehicles designed to support long-term financial security during post-employment years. These accounts—primarily Individual Retirement Accounts (IRAs) and employer-sponsored plans such as 401(k)s—offer significant tax advantages to incentivize consistent saving. The Internal Revenue Service (IRS) sets and periodically adjusts contribution limits for these accounts to account for inflation. Given their unique regulatory and tax characteristics, retirement accounts differ from standard brokerage or investment accounts. When documenting them in Beancount, a plain-text double-entry accounting system, a structured approach is necessary to track both contributions and IRS-imposed limits. ...
Recording Real Estate in Beancount
Managing real estate investments involves tracking numerous financial activities, including property purchases, rental income, and eventual sales. This guide illustrates how to leverage Beancount, a plain-text double-entry accounting system, to accurately model real estate transactions. By structuring appropriate accounts for assets, liabilities, income, and expenses, readers will learn to document key financial events such as down payments, mortgage servicing, rent collection, and asset appreciation. Whether you’re an experienced investor or just beginning your property journey, this article offers a clear framework for maintaining transparent and comprehensive financial records. ...
Beancount Concepts
Understanding the foundational principles of Beancount is essential for effective personal finance management. This post delves into the core concepts that underpin Beancount’s plain-text double-entry accounting system. You’ll explore how every transaction must be balanced, the five fundamental account types (Assets, Liabilities, Equity, Income, Expenses), and the role of commodities in tracking various assets. Additionally, the article introduces key financial statements like the balance sheet and income statement, illustrating how Beancount provides a clear and structured view of your financial health. Whether you’re new to Beancount or seeking to solidify your understanding, this guide offers a comprehensive overview of its conceptual framework. ...