.NET Core

It is very easy to get started with .NET Core on your platform of choice.

You just need a shell, a text editor and 10 minutes of your time.

Install for Windows

  1. 1

    Install .NET Core SDK

    The best way to develop with .NET Core on Windows is using Visual Studio. You can download Visual Studio Community 2015 for free. Download and install:

    You can also develop .NET Core apps from the command-line by downloading the .NET Core SDK for Windows. You can use your own editor, or with Visual Studio Code (free).

  2. 2

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  3. 3

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  4. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  5. Want some tools?

    Visual Studio Community is a great IDE available for no charge, but you can also try out Visual Studio Code for a lightweight code editing experience. Visual Studio Code runs on Windows (and other platforms as well!) and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get a great code editing experience.

Install for Red Hat Enterprise Linux 7 Server

  1. 1

    Enable the .NET Core channel for Red Hat Enterprise Linux 7 Server

    In order to install .NET Core from Red Hat on RHEL Server, you first need to enable the .NET Core channel which is available under your RHEL 7 Server subscription. You also need to ensure that your system supports enabling software collections via the scl tool.

    1. subscription-manager repos --enable=rhel-7-server-dotnet-rpms
    2. yum install scl-utils

    For help on registering your machine to get access to the channel see the Chapter 1 of the .NET Core Getting Started Guide at Red Hat.

  2. 2

    Install and enable the .NET Core SDK

    Now you can install .NET Core and then enable the .NET Core software collection.

    For additional help and guidance on installing and enabling .NET Core on RHEL Server, see the .NET Core Getting Started Guide at Red Hat

    1. yum install rh-dotnetcore10
    2. scl enable rh-dotnetcore10 bash
  3. 3

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  4. 4

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  5. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  6. Want some tools?

    Visual Studio Code runs on RHEL and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get the best experience.

Install for CentOS 7.1 & Oracle Linux 7.1

  1. 1

    Install .NET Core SDK

    Before you start, please remove any previous versions of .NET Core from your system.

    In order to install .NET Core on CentOS or Oracle Linux, first you need to get the prerequisites and then you download the .NET Core SDK binaries, extract them onto your system and put dotnet onto your PATH.

    1. sudo yum install libunwind libicu
    2. curl -sSL -o dotnet.tar.gz https://go.microsoft.com/fwlink/?LinkID=827529
    3. sudo mkdir -p /opt/dotnet && sudo tar zxf dotnet.tar.gz -C /opt/dotnet
    4. sudo ln -s /opt/dotnet/dotnet /usr/local/bin
  2. 2

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  3. 3

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  4. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  5. Want some tools?

    Visual Studio Code runs on Linux and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get the best experience.

Install for Debian 8

  1. 1

    Install .NET Core SDK

    Before you start, please remove any previous versions of .NET Core from your system.

    In order to install .NET Core on Debian, first you need to get the prerequisites and then you download the .NET Core SDK binaries, extract them onto your system and put dotnet onto your PATH.

    1. sudo apt-get install curl libunwind8 gettext
    2. curl -sSL -o dotnet.tar.gz https://go.microsoft.com/fwlink/?LinkID=827530
    3. sudo mkdir -p /opt/dotnet && sudo tar zxf dotnet.tar.gz -C /opt/dotnet
    4. sudo ln -s /opt/dotnet/dotnet /usr/local/bin
  2. 2

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  3. 3

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  4. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  5. Want some tools?

    Visual Studio Code runs on Linux and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get the best experience.

Install for Fedora 23

  1. 1

    Install .NET Core SDK

    Before you start, please remove any previous versions of .NET Core from your system.

    In order to install .NET Core on Fedora, first you need to get the prerequisites and then you download the .NET Core SDK binaries, extract them onto your system and put dotnet onto your PATH.

    1. sudo dnf install libunwind libicu
    2. curl -sSL -o dotnet.tar.gz https://go.microsoft.com/fwlink/?LinkID=827531
    3. sudo mkdir -p /opt/dotnet && sudo tar zxf dotnet.tar.gz -C /opt/dotnet
    4. sudo ln -s /opt/dotnet/dotnet /usr/local/bin
  2. 2

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  3. 3

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  4. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  5. Want some tools?

    Visual Studio Code runs on Linux and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get the best experience.

Install for openSUSE 13.2

  1. 1

    Install .NET Core SDK

    Before you start, please remove any previous versions of .NET Core from your system.

    In order to install .NET Core on openSUSE, first you need to get the prerequisites and then you download the .NET Core SDK binaries, extract them onto your system and put dotnet onto your PATH.

    1. sudo zypper install libunwind libicu
    2. curl -sSL -o dotnet.tar.gz https://go.microsoft.com/fwlink/?LinkID=827532
    3. sudo mkdir -p /opt/dotnet && sudo tar zxf dotnet.tar.gz -C /opt/dotnet
    4. sudo ln -s /opt/dotnet/dotnet /usr/local/bin
  2. 2

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  3. 3

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  4. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  5. Want some tools?

    Visual Studio Code runs on Linux and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get the best experience.

Install for Ubuntu 14.04, 16.04 & Linux Mint 17

  1. 1

    Add the dotnet apt-get feed

    In order to install .NET Core on Ubuntu or Linux Mint, you need to first set up the apt-get feed that hosts the package you need.

    Ubuntu 14.04 / Linux Mint 17

    1. sudo sh -c 'echo "deb [arch=amd64] https://apt-mo.trafficmanager.net/repos/dotnet-release/ trusty main" > /etc/apt/sources.list.d/dotnetdev.list'
    2. sudo apt-key adv --keyserver apt-mo.trafficmanager.net --recv-keys 417A0893
    3. sudo apt-get update

    Ubuntu 16.04

    1. sudo sh -c 'echo "deb [arch=amd64] https://apt-mo.trafficmanager.net/repos/dotnet-release/ xenial main" > /etc/apt/sources.list.d/dotnetdev.list'
    2. sudo apt-key adv --keyserver apt-mo.trafficmanager.net --recv-keys 417A0893
    3. sudo apt-get update
  2. 2

    Install .NET Core SDK

    Before you start, please remove any previous versions of .NET Core from your system by using this script.

    To .NET Core on Ubuntu or Linux Mint, simply use apt-get.

    1. sudo apt-get install dotnet-dev-1.0.0-preview2-003131
  3. 3

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  4. 4

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  5. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  6. Want some tools?

    Visual Studio Code runs on Linux and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get the best experience.

Install for Mac OS X 10.11

  1. 1

    Install pre-requisites

    In order to use .NET Core, you first need to install the latest version of OpenSSL. The easiest way to get this is from Homebrew. After installing brew, do the following:

    1. brew update
    2. brew install openssl
    3. ln -s /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib /usr/local/lib/
    4. ln -s /usr/local/opt/openssl/lib/libssl.1.0.0.dylib /usr/local/lib/
  2. 2

    Install .NET Core SDK

    The best way to install .NET Core on macOS is to download the official installer. This installer will install the tools and put them on your PATH so you can run dotnet from the Console

    Note: if you have any problems with installation on macOS, please consult our known issues page.

  3. 3

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  4. 4

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  5. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  6. Want some tools?

    Visual Studio Code runs on macOS and has full support for .NET Core. Download Visual Studio Code for free and install the C# extension from the marketplace to get the best experience.

Install for Docker

  1. 1

    Install Docker

    Before you can try out the .NET Core Docker base images, you should install Docker.

    Refer to the macOS, Windows or Linux getting started instructions for Docker to learn more about installing Docker.

  2. 2

    Run the container using "dotnet" base image

    The following command will get you a running container with the toolchain, straight off of Microsoft's Docker Hub.

    1. docker run -it microsoft/dotnet:latest
  3. 3

    Initialize some code

    Let's initialize a sample Hello World application!

    1. mkdir hwapp
    2. cd hwapp
    3. dotnet new
  4. 4

    Run the app

    The first command will restore the packages specified in the project.json file, and the second command will run the actual sample:

    1. dotnet restore
    2. dotnet run
  5. And you're ready!

    You now have .NET core running on your machine!

    You can create a website with ASP.NET Core or you can visit the .NET Core on GitHub for more samples. Take a look at the .NET Documentation to learn more about .NET Core, use one of our interactive online tutorials or get involved with the community to learn more about .NET Core!

  6. Want some tools?

    On Windows, Visual Studio provides a great development experience for Docker containers, you can download Visual Studio Community 2015 for free and the Docker tools for Visual Studio.

    You can also try out Visual Studio Code for a lightweight code editing experience which runs everywhere (including Mac and Linux). Download Visual Studio Code for free and install the C# extension from the marketplace to get a great code editing experience along with the Docker Tools for VS Code. If you use Yeoman, then take a look at yo docker to help you create, run and debug your .NET Core project inside of a Docker container.