How to install .NET SDK in Ubuntu 20.04

To install .NET on ubuntu 20.04, run the following commands

wget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
sudo apt-get update
sudo apt-get install -y apt-transport-https
sudo apt-get update

To find all versions of .NET SDK available, run

apt-cache search dotnet-sdk
dotnet sdk ubuntu

To install .NET SDK version 6, run

Advertisement

apt install dotnet-sdk-6.0

For .NET SDK 5, run

apt install dotnet-sdk-5.0

For .NET SDK 3.1, run

apt install dotnet-sdk-3.1

For .NET SDK 2.1, run

apt install dotnet-sdk-2.1

Back to dotnet

Add a comment

Leave a Reply

Your email address will not be published. Required fields are marked *

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Advertisement