Download the compiler

You can download the latest version of the Nim compiler here.

Note: The Nim compiler requires a C compiler to compile software. On Windows we recommend that you use Mingw-w64. GCC is recommended on Linux and Clang on Mac.

Binaries

Unfortunately for now we only provide builds for Windows.

Installation based on generated C code

This installation method is the preferred way for Linux, Mac OS X, and other Unix like systems. Binary packages may be provided later.

Download one of these:

Extract the file and follow these instructions:

  • sh build.sh
  • Add $your_install_dir/bin to your PATH.

There are other ways to install Nim (like using the install.sh script), but these tend to cause more problems.

Installation from github

Use the following commands to build the compiler from source. Change the branch to suit your needs:

git clone -b master git://github.com/Araq/Nim.git
cd Nim
git clone -b master --depth 1 git://github.com/nim-lang/csources
cd csources && sh build.sh
cd ..
bin/nim c koch
./koch boot -d:release

The master branch always contains the latest stable version of the compiler. If you want bleeding edge then switch to the devel branch and follow the same instructions outlined above.