Get Started on Visual Studio 2022

This getting started will guide you through setting up your environment to create Uno Platform applications using C# and .NET with Visual Studio 2022.

Tip

If you want to use another environment or IDE, see our general getting started.

Install Visual Studio with Workloads

To create Uno Platform applications you will need Visual Studio 2022 17.8 or later:

  1. ASP.NET and web development workload installed (for WebAssembly development)

    Visual Studio Installer - ASP.NET and web development workload

  2. .NET Multi-platform App UI development workload installed (for iOS, Android, Mac Catalyst development).

    Visual Studio Installer - .NET Multi-platform App UI development workload

  3. .NET desktop development workload installed (for Skia-based targets development)

    Visual Studio Installer - .NET desktop development workload

Important

Uno Platform 5.0 does not support Xamarin projects anymore. To build Xamarin-based projects in Visual Studio 2022, in Visual Studio's installer Individual components tab, search for Xamarin and select Xamarin and Xamarin Remoted Simulator. See this section on migrating Xamarin projects to .NET 6.

Check your environment

  1. Open a command-line prompt, Windows Terminal if you have it installed, or else Command Prompt or Windows Powershell from the Start menu.

  2. Setup uno.check by:

    • Installing the tool:

      dotnet tool install -g uno.check
      
    • Updating the tool, if you previously installed it:

      dotnet tool update -g uno.check
      
  3. Run the tool from the command prompt with the following command:

    uno-check
    
  4. Follow the instructions indicated by the tool.

Install the Uno Platform Extension

  1. Launch Visual Studio 2022, then click Continue without code. Click Extensions -> Manage Extensions from the Menu Bar.

    Visual Studio - "Extensions" drop-down selecting "Manage Extensions"

  2. In the Extension Manager expand the Online node and search for Uno, install the Uno Platform extension or download it from the Visual Studio Marketplace, then restart Visual Studio.

    Extension Manager - Uno Platform extension

Additional Setup for Windows Subsystem for Linux (WSL)

It is possible to build and debug Skia Desktop projects under WSL if you choose to do so.

To setup your environment for WSL:

  • Install WSL Ubuntu 22.04 or later
  • Install the prerequisites for Linux mentioned below, in your installed distribution using the Ubuntu shell
Note

Running Uno Platform apps using WSL makes use of WSLg's support for Wayland.

Additional Setup for Skia Desktop projects

WSL

  • Install the required dependencies:

    sudo apt update
    sudo apt-get install mesa-utils libgl1-mesa-glx ttf-mscorefonts-installer dbus libfontconfig1 libxrandr
    

You may also need to install the Microsoft fonts manually.

If you are using Windows Subsystem for Linux (WSL), you can find specific instructions in the following video:



Next Steps

You're all set! You can create your first Uno Platform app.