# Hledger — Robust Plain-Text Accounting Tool > A cross-platform accounting program for tracking money, time, or any quantity using plain-text journal files, with terminal, web, and API interfaces. ## Install Save in your project root: # Hledger — Robust Plain-Text Accounting Tool ## Quick Use ```bash # Install brew install hledger # macOS sudo apt install hledger # Debian/Ubuntu stack install hledger # via Haskell Stack # Quick start cat > journal.hledger << EOF 2026-05-01 Opening Balance assets:checking 10000.00 equity:opening 2026-05-05 Rent Payment expenses:rent 1500.00 assets:checking 2026-05-10 Freelance Income assets:checking 3000.00 income:freelance EOF hledger -f journal.hledger balance hledger -f journal.hledger incomestatement hledger-web -f journal.hledger # Opens web UI ``` ## Introduction Hledger is a plain-text accounting tool inspired by Ledger, rewritten in Haskell for reliability and extended with a web interface and additional reporting capabilities. It reads simple text-based journal files and produces financial reports via CLI, web browser, or JSON API. ## What Hledger Does - Reads plain-text journal files and generates balance sheets, income statements, and cash flow reports - Provides a web interface (hledger-web) for browsing accounts and adding transactions - Supports multi-currency transactions with automatic and manual price conversion - Tracks time as well as money, useful for freelancers and consultants - Offers a JSON API for integrating with custom dashboards and tools ## Architecture Overview Hledger is built in Haskell with separate packages for the core library, CLI, web UI, and API server. The core parses journal files into a transaction stream, applies account aliases and valuation rules, and produces report data structures. The web interface uses the Yesod framework and can run as a local or networked server. ## Self-Hosting & Configuration - Install via OS package managers, Haskell Stack, or pre-built binaries - Store journal files as plain text in any directory, optionally under version control - Configure account aliases, default commodity, and display formats in the journal file header - Run hledger-web for a browser-based interface with add/edit capabilities - Use environment variable LEDGER_FILE to set the default journal path ## Key Features - Compatible with Ledger file format while adding stricter error checking - Built-in web UI for non-technical users to browse reports and enter transactions - Comprehensive date and period filtering for custom report ranges - CSV import rules engine for automated bank statement conversion - Time tracking mode for logging billable hours alongside financial data ## Comparison with Similar Tools - **Ledger** — The C++ original; hledger adds a web UI, stricter parsing, and CSV import rules - **Beancount** — Python-based with Fava UI; hledger uses Ledger-compatible syntax and Haskell reliability - **GnuCash** — Desktop GUI with database; hledger is text-first with version-control integration - **Actual Budget** — Web-based envelope budgeting; hledger is a general accounting tool with more flexibility ## FAQ **Q: Is hledger compatible with Ledger files?** A: Mostly yes. Hledger reads Ledger-format journals with minor syntax differences documented in the manual. **Q: Can I use hledger without the command line?** A: Yes, hledger-web provides a full web interface for viewing reports and adding transactions. **Q: Does hledger support budgeting?** A: Yes, it supports periodic budget declarations and can report actuals vs. budget. **Q: Is Haskell required to use hledger?** A: No, pre-built binaries are available. Haskell is only needed if building from source. ## Sources - https://github.com/simonmichael/hledger - https://hledger.org --- Source: https://tokrepo.com/en/workflows/asset-2468a83a Author: AI Open Source