Use F# on Windows
Option 1: Install the Visual F# Tools from Microsoft
On Windows, F# programmers commonly use the Visual F# Tools from Microsoft.
Visual Studio 2017 comes with F# support in all its editions: Community, Professional and Enterprise. The installer includes it with some of the selectable workloads, or you can select it manually in the “Individual components” tab: under the “Development activities” category, check “F# language support”.
If you already have Visual Studio 2012/13/15 Professional or above, you can use that. All recent versions of Visual Studio come with the Visual F# Tools. The Visual F# Tools are installed automatically when you first create or open an F# project. You can also install the support directly as a separate download.
Otherwise, install the free Visual Studio 2015 Community.
See Visual F# Resources for more information about the Visual F# Tools from Microsoft.
In addition, install the community-provided Visual F# Power Tools, for use with Visual Studio 2013 and 2015. They include source code formatting, auto-generating XML Docs, highlight and find references, rename refactoring, depth colorizer, implement interface, record stub generation, union pattern match case generation and the navigate-to command.
Visual Studio 2017 doesn’t need the Power Tools, because it includes most of their functionality out of the box.
Option 2: Install Visual Studio Code
- Install Visual Studio Code for Windows
Ctrl+Pand enter the following to install the Ionide package for VS Code.
ext install Ionide-fsharp
You will also need to install the free F# compiler and command line tools in Step 3.
Option 3: Install the free F# compiler and tools alone
If you’re just looking for F# command-line tools, e.g. for a build server or cloud VM image, then use the following requirements and installation steps:
Requires .NET 4.5:
On Windows 10 .NET 4.6 is already present by default
On Windows 8 and Windows 2012 Server, this is already present by default
On Windows 7 and Windows 2008 Server, install .NET 4.5 from Microsoft
Requires the Windows SDK:
On Windows 10 use the Windows 10 and .NET 4.6 SDK from Microsoft
On Windows 8.1 use the Windows 8.1 and .NET 4.5.1 SDK from Microsoft
On Windows 8 or Windows 2012 Server use the Windows 8 and .NET 4.5 SDK from Microsoft
On Windows 7 or Windows 2008 Server use the Windows 7 and .NET 4.0 SDK from Microsoft
Requires Microsoft Build Tools 2015 - Install Microsoft Build Tools 2015
Install the free Visual F# Tools 4.0 from Microsoft
Alternatively, do a quiet install from a PowerShell administrator prompt (the URL is the redirect of the above).
$webclient = New-Object Net.WebClient $url = 'http://download.microsoft.com/download/9/1/2/9122D406-F1E3-4880-A66D-D6C65E8B1545/FSharp_Bundle.exe' $webclient.DownloadFile($url, "$pwd\FSharp_Bundle.exe") .\FSharp_Bundle.exe /install /quiet
The compiler tools on 64-bit Windows are installed at
C:\Program Files (x86)\Microsoft SDKs\F#\4.0\Framework\v4.0\fsc.exe C:\Program Files (x86)\Microsoft SDKs\F#\4.0\Framework\v4.0\fsi.exe C:\Program Files (x86)\Microsoft SDKs\F#\4.0\Framework\v4.0\fsiAnyCpu.exe
The compiler tools on 32-bit Windows are installed at
C:\Program Files\Microsoft SDKs\F#\4.0\Framework\v4.0\fsc.exe C:\Program Files\Microsoft SDKs\F#\4.0\Framework\v4.0\fsi.exe C:\Program Files\Microsoft SDKs\F#\4.0\Framework\v4.0\fsiAnyCpu.exe
If you’re looking for Visual F# Tools 3.0 specifically, its standalone version could be downloaded here.
Option 4: Run already compiled F# code on servers
Compiled F# code depends on the FSharp.Core.dll assembly. This file is not part of a standard .NET installation, so in order to execute applications written in F# on servers (or other machines without developer tools), it must be installed or bundled with your application. The recommended procedure is to bundle this component with your final application. The Visual F# Tools downloads from Microsoft installs FSharp.Core.dll into GAC.
Option 5: Build F# from source
Build and contribute to the F# compiler and library from the source