Skip to content
Follow
Ubuntu Linux

Install .NET 8.0 on Ubuntu 24.04

Richard
Written by
Richard
Mar 5, 2025 Updated Jul 13, 2026 2 min read
Install .NET 8.0 on Ubuntu 24.04
Install .NET 8.0 on Ubuntu 24.04

.NET 8.0 on Ubuntu 24.04 installs using Ubuntu’s standard package manager, APT.

.NET 8.0 is Microsoft’s platform for building all sorts of modern applications, like websites or desktop programs. Installing it lets you run .NET software on your Ubuntu 24.04 computer.

This version, .NET 8.0, is the latest stable release. Using Ubuntu’s built-in tools makes getting it onto your system straightforward.

⚡ Quick Answer

Install .NET 8.0 on Ubuntu 24.04 by running `sudo apt update` followed by `sudo apt install dotnet8`. Verify the installation with `dotnet –version`.

Install .NET 8

.NET 8 Ubuntu 24.04 can be installed using commands in your terminal. This method uses your system’s package manager to quickly obtain the latest version. Open your terminal and type the commands provided to start using .NET 8 right away.

Run the command below to install .NET 8 on Ubuntu.

🐧Bash / Shell
sudo apt update
sudo apt install dotnet8

Once installed, run the command below to verify the .NET version number.

💻Code
dotnet --version

Create Hello World app

Check your .NET 8 installation on Ubuntu 24.04 by creating a ‘Hello World’ app. This basic program lets you test if everything is set up correctly. Create the app with the command `dotnet new console -o helloworld`, then change into the new directory.

Run the command below to create a simple Hello World app.

💻Code
dotnet new console -o helloworld

Change into the helloworld folder and run the app.

Command Prompt
cd helloworld
dotnet run

It should output [Hello World] on your terminal.

Creating an ASP.NET app is also possible. To do that, run the command below.

💻Code
dotnet new razor -o asp.net

Change into the [asp.net] folder and run the app.

Command Prompt
cd asp.net
dotnet run --urls=http://0.0.0.0:5000/

To test, open your browser and navigate to the server hostname or IP address followed by port number 5000.

💻Code
http://srv1.example.com:5000
.NET app portal
.NET app portal

That should do it!

Conclusion:

Installing and using .NET 8 on Ubuntu 24.04 offers many advantages for developers. Key points to remember include:

  • Cross-Platform Development: .NET 8 allows for the development of applications across various platforms.
  • Streamlined Installation: Installation has been simplified with packages available in the default repositories.
  • Easy Verification: The command to check the .NET version allows for quick installation confirmation.
  • Hello World Example: Creating a basic “Hello World” app helps beginners start with .NET 8.
  • ASP.NET Capability: Developers can easily create and run ASP.NET applications for web development.
  • Accessibility: Applications can be accessed via a web browser, demonstrating successful deployment.

These benefits empower developers to build robust applications efficiently.

Can I run .NET 8 on Linux?

Download .NET 8.0 (Linux, macOS, and Windows) .NET. Want to try out the latest preview? .NET 11.0.0-preview.2 is available.

Can I run .NET on Ubuntu?

Starting with Ubuntu 22.04, most supported versions of . NET are available in the built-in Ubuntu feed. The Ubuntu . NET backports package repository contains the remaining supported .

Was this guide helpful?

Was this helpful?
Richard

About the Author

Richard

Tech Writer, IT Professional

Richard, a writer for Geek Rewind, is a tech enthusiast who loves breaking down complex IT topics into simple, easy-to-understand ideas. With years of hands-on experience in system administration and enterprise IT operations, he’s developed a knack for offering practical tips and solutions. Richard aims to make technology more accessible and actionable. He's deeply committed to the Geek Rewind community, always ready to answer questions and engage in discussions.

📚 Related Tutorials

How to Install GNOME Desktop on Ubuntu 24.04
Ubuntu Linux How to Install GNOME Desktop on Ubuntu 24.04
How to Install KDE Desktop on Ubuntu 24.04
Ubuntu Linux How to Install KDE Desktop on Ubuntu 24.04
Advanced Windows 11 Guide For Developers
Windows Advanced Windows 11 Guide For Developers

No comments yet — be the first to share your thoughts!

Leave a Comment

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