A step by step tutorial for installing Fantom on Windows

For those of you with a Java background, you'll be pleased to know that installing Fantom is no different from installing ant or maven. Essentially you unzip the Fantom installation and update your PATH environment variable to point to Fantom's bin/ directory.

For those of you who don't have a Java background, then what follows are detailed installation instructions.

Further information is available on the official Fantom site.


There's an easy way, and a hard way. The easy way is to just download and run:

Fantom Windows Installer - by Steve Eynon

The hard way is to do a manual install:

  1. Install Java

    First and foremost, ensure you have Java installed.

  2. Download Fantom

    Download Fantom from http://fantom.org

    The fantom installation is just a .zip file ~ 15Mb

  3. Unzip Fantom Installation

    Unzip Fantom to somewhere convenient, like C:\Apps\fantom-1.0.69\

  4. Create the FAN_HOME environment variable

    FAN_HOME should point to the directory you've just unzipped Fantom into, example:

    Creating the 'FAN_HOME' environment variable

    Note how the variable does NOT end with a /slash/.

    I tend to set my User variables and not my System variables; as I'm the only user of my machine I just find it's neater.

    I include the version number in my installation directory. That way I can have multiple versions of Fantom on my system and switch between them by changing the FAN_HOME environment variable to point to the version I want to use.

  5. Update the PATH environment variable

    The PATH environment variable needs to point to ;%FAN_HOME%\bin so it can pick up fan.exe. This is the Fantom launcher used to run Fantom code.

    Updating the 'PATH' environment variable

    Again, I tend to change the PATH User variable.

  6. Test the Installation

    Test your installation by running: fan -version on the command line. You should see something like:

    select all
    C:\>fan -version
    Fantom Launcher
    Copyright (c) 2006-2012, Brian Frank and Andy Frank
    Licensed under the Academic Free License version 3.0
    Java Runtime:
      java.version:    1.6.0_45
      java.vm.name:    Java HotSpot(TM) 64-Bit Server VM
      java.vm.vendor:  Sun Microsystems Inc.
      java.vm.version: 20.14-b01
      java.home:       C:\Apps\Java\jdk1.6.0_45\jre
      fan.platform:    win32-x86_64
      fan.version:     1.0.69
      fan.env:         sys::BootEnv
      fan.home:        C:\Apps\fantom-1.0.69

    Note that after changing the environment variables, you'll need to open a new Command Prompt for the variables to take effect.

    See Setup on the official documentation for more details.

Mac OS X

When installing Fantom on Mac OS X follow Fantom's Setup Instuctions for Unix but, as per Apple's guidelines for file system layout, install Fantom into the ~/Library/Frameworks/Fantom/ directory.

See OS X Library Directory Details and The Library Directory Stores App-Specific Files for details.


Now you've successully installed Fantom, try your hand at a Hello World! program!

Have fun!


  • 31 July 2016 - Removed the section for Windows 64 bit as since Fantom 1.0.68 it is now the same as Windows 32 bit.
  • 22 Jul 2014 - Added specific Windows 64 bit section.
  • 1 Nov 2013 - Original article.