How to record journal entries

There are many ways to create hledger journal entries. Here are some options:


With a text UI

With a web UI

On a phone or tablet

In a text editor

From scratch

  • Write the entry in full, using journal format.
  • As above, but also use editor addons to assist (like Emacs ledger-mode's TAB account completion and M-q alignment).

From templates

  • In Emacs with yasnippet configured (eg), enter the name of a snippet and complete with TAB

From past entries

  • Find, copy and modify a past entry in the journal
  • Or in Emacs ledger-mode, enter a date and partial description and complete with C-c TAB

From future entries

  • Move the entry from a separate file where you prepared it ahead of time (eg future.journal)

At the command line

From scratch

  • Write the entry using journal format, eg
    $ cat >>$LEDGER_FILE
        expenses:food   $10
    printf >>$LEDGER_FILE '2023-01-01\n  expenses:food  $10\n  assets:cash\n\n'

From past entries

From periodic transaction / auto posting rules

From custom scripts

  • If you have custom scripts to help with tasks, make them print or append journal entries when appropriate. Eg have your invoicing script add an invoice transaction to the journal.

By converting data

From bank CSV (or other character-separated values)

From timeclock, timedot or other journal files

  • Just read them directly with -f
  • Or, hledger import them to main journal

From other apps or data formats