Here are some ways to install hledger. Binary packages will install quickly, or you can run our install script, or build with stack/cabal. Please do report any trouble. The current hledger release is: 1.15.2 (release notes).

Binary packages

Linux, Mac
nix-env -f -iA hledger hledger-web hledger-ui
On Linux, note #1030, #1033
Linux, Mac, Windows
docker pull dastapov/hledger
Linux, Mac, Windows
brew install hledger
Linux, Mac, FreeBSD
Install Wine and use the Windows binary
Appveyor builds
Windows release Windows nightly
pacman -S hledger hledger-ui hledger-web
sudo layman -a haskell && sudo emerge hledger hledger-ui hledger-web
Void Linux x86_64
xbps-install -S hledger hledger-ui hledger-web
sudo apt install hledger hledger-ui hledger-web
sudo dnf install hledger
sudo apt install hledger hledger-ui hledger-web
make -C /usr/ports/openbsd-wip/productivity/hledger install

Building from source

You can build hledger wherever the Glasgow Haskell Compiler is supported. This can take a while, but it’s normally a reliable process. Use one of the tools below to build the current hledger release. On Windows, hledger-ui is not available and should be omitted from the commands below (except in WSL).

Linux, Mac, WSL
The hledger-install script requires only bash. It's good practice to inspect the script and satisfy yourself that it's safe before running it. It runs stack or cabal for you, installing stack if needed. It installs the main hledger tools plus some addons (hledger-iadd, hledger-interest).
curl -sO
Linux, Mac, Windows
The latest version of stack (2.1.3 as of 2019-07) will likely work best, so we recommend it. If you have an older version, you can usually upgrade quickly with stack upgrade. Versions older than 1.7.1 will not work. On Windows, the 64-bit version of stack is recommended.
stack update
stack install --resolver=lts-14.3 hledger-lib-1.15.2 hledger-1.15.2 hledger-web-1.15 hledger-ui-1.15 --silent
Linux, Mac, Windows
cabal v2-update
cabal v2-install hledger-1.15.2 hledger-web-1.15 hledger-ui-1.15

Build tips

Building the development version

The master branch in hledger’s github repo is suitable for daily use, and includes the latest improvements. You’ll need git and stack or cabal. This will build and install all of the main hledger tools using stack:

git clone
cd hledger
stack install

cabal users may find the or cabal.project files useful.

Development builds of hledger show a .99 suffix in their --version output, meaning “dev”. So 1.15.99 means “1.16-dev”, the in-development version of 1.16.

Building the development version with Docker

You can also build the development version in a Docker container which will take care of pulling all the necessary tools and dependencies:

git clone
cd hledger/docker

This will build the image tagged hledger with just the latest binaries inside.

If you want to keep all the build artifacts and use the resulting image for hledger development, run ./ instead.

Check your PATH

After building/installing, you may see a message about where the executables were installed. Eg:

  • with stack: $HOME/.local/bin (on Windows, %APPDATA%\local\bin)

  • with cabal: $HOME/.cabal/bin (on Windows, %APPDATA%\cabal\bin)

  • with nix: $HOME/.nix-profile/bin

Make sure that this install directory is included in your shell’s $PATH (preferably near the start, to preempt any old hledger binaries you might have lying around), so that you can run the hledger tools easily. How to configure this depends on your platform and shell. If you are using bash, this will show it:

echo $PATH

and here’s a way to add the stack and cabal install dirs permanently:

echo "export PATH=~/.local/bin:~/.cabal/bin:$PATH" >> ~/.bashrc
source ~/.bashrc

Test your installation

After a successful installation, you should be able to run the hledger tools (that you installed), and see the expected versions. Eg:

$ hledger --version
hledger 1.15.2
$ hledger-ui --version
hledger-ui 1.15
$ hledger web --version
hledger-web 1.15
$ hledger iadd --version
This is hledger-iadd version 1.3.9

And you could see the unit tests pass (just for fun):

$ hledger test
199 tests passed, no failures!

Nicely done. Next, see the Getting Started docs in the sidebar, such as the Basics tutorial, or introduce yourself in the IRC channel/Matrix room.