Prerequisites for .NET Core on Windows
This article shows the dependencies needed to develop .NET Core applications on Windows. The supported OS versions and dependencies that follow apply to the three ways of developing .NET Core apps on Windows:
.NET Core supported Windows versions
.NET Core is supported on the following versions of:
- Windows 7 SP1
- Windows 8.1
- Windows 10 Anniversary Update (version 1607) or later versions
- Windows Server 2008 R2 SP1 (Full Server or Server Core)
- Windows Server 2012 SP1 (Full Server or Server Core)
- Windows Server 2012 R2 (Full Server or Server Core)
- Windows Server 2016 or later versions (Full Server, Server Core, or Nano Server)
The following articles have a complete list of .NET Core supported operating systems per version:
- .NET Core 2.1 - Supported OS Versions
- .NET Core 2.0 - Supported OS Versions
- .NET Core 1.x - Supported OS Versions
.NET Core dependencies
.NET Core 1.1 and earlier versions require the Visual C++ Redistributable when running on Windows versions earlier than Windows 10 and Windows Server 2016. This dependency is automatically installed by the .NET Core installer.
Microsoft Visual C++ 2015 Redistributable Update 3 must be manually installed when:
- Installing .NET Core with the installer script.
- Deploying a self-contained .NET Core application.
- Building the product from source.
- Installing .NET Core via a .zip file. This can include build/CI/CD servers.
For Windows 8.1 and earlier versions, or Windows Server 2012 R2 and earlier versions:
Make sure that your Windows installation is up-to-date and includes KB2999226, which can be installed through Windows Update. If you don't have this update installed, you'll see an error like the following when you launch a .NET Core application:
The program can't start because api-ms-win-crt-runtime-1-1-0.dll is missing from your computer. Try reinstalling the program to fix this problem.
For Windows 7 or Windows Server 2008 R2:
In addition to KB2999226, make sure you also have KB2533623 installed. If you don't have this update installed, you'll see an error similar to the following when you launch a .NET Core application:
The library hostfxr.dll was found, but loading it from C:\<path_to_app>\hostfxr.dll failed.
Prerequisites with Visual Studio 2017
You can use any editor to develop .NET Core applications using the .NET Core SDK. Visual Studio 2017 provides an integrated development environment for .NET Core apps on Windows.
You can read more about the changes in Visual Studio 2017 in the release notes.
To develop .NET Core 2.x apps in Visual Studio 2017:
- Download and install Visual Studio 2017 version 15.3.0 or higher with the .NET Core cross-platform development workload (in the Other Toolsets section) selected.
After the .NET Core cross-platform development toolset is installed, Visual Studio 2017 uses .NET Core 1.x by default. Install the .NET Core 2.x SDK to get .NET Core 2.x support in Visual Studio 2017.
- Install the .NET Core 2.x SDK.
- Retarget existing or new .NET Core 1.x projects to .NET Core 2.x using the following instructions:
- On the Project menu, Choose Properties.
- In the Target framework selection menu, set the value to .NET Core 2.0.
Once the .NET Core 2.x SDK is installed, Visual Studio 2017 uses the .NET Core SDK 2.x by default, and supports the following actions:
- Open, build, and run existing .NET Core 1.x projects.
- Retarget .NET Core 1.x projects to .NET Core 2.x, build, and run.
- Create new .NET Core 2.x projects.
To verify your Visual Studio 2017 version:
- On the Help menu, choose About Microsoft Visual Studio.
- In the About Microsoft Visual Studio dialog, verify the version number.
- For .NET Core 2.1 RC apps, Visual Studio 2017 version 15.7 or higher.
- For .NET Core 2.0 apps, Visual Studio 2017 version 15.3 or higher.
- For .NET Core 1.x apps, Visual Studio 2017 version 15.0 or higher.