.NET Multi-platform App UI (.NET MAUI) is a cross-platform framework for creating native mobile and desktop apps with C# and XAML. Using .NET MAUI, you can develop apps that can run on Android, iOS, macOS, Tizen, and Windows from a single shared codebase.
$ dotnet add package Microsoft.Maui.Controls
.NET Multi-platform App UI (.NET MAUI) is a cross-platform framework for creating native mobile and desktop apps with C# and XAML. Using .NET MAUI, you can develop apps that run on Android, iOS, iPadOS, macOS, and Windows from a single shared codebase.
The Microsoft.Maui.Controls package provides the UI controls and XAML infrastructure for building beautiful, native cross-platform applications. It includes:
.NET MAUI applications run on the following platforms:
| Platform | Minimum Version |
|---|---|
| Android | API 21 (Android 5.0) |
| iOS | iOS 13.0+ |
| iPadOS | iPadOS 13.0+ |
| macOS | macOS 12.0+ (via Mac Catalyst) |
| Windows | Windows 11, Windows 10 (Version 1809+) using Windows UI Library (WinUI) |
Install the .NET MAUI workload:
dotnet workload install maui
Create a new .NET MAUI app using the CLI:
dotnet new maui -n MyMauiApp
cd MyMauiApp
Or create with sample content including Community Toolkit and Syncfusion Toolkit:
dotnet new maui -n MyMauiApp -sc
Run on Android:
dotnet build -t:Run -f net10.0-android
Run on iOS (Mac only):
dotnet build -t:Run -f net10.0-ios
Run on Mac Catalyst (Mac only):
dotnet build -t:Run -f net10.0-maccatalyst
Run on Windows:
dotnet build -t:Run -f net10.0-windows10.0.19041.0
Here's a simple .NET MAUI page to get you started:
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml">
<VerticalStackLayout Padding="30" Spacing="25">
<Label Text="Hello, .NET MAUI!"
FontSize="32"
HorizontalOptions="Center" />
<Button Text="Click Me"
Clicked="OnButtonClicked" />
<Label x:Name="CounterLabel"
Text="Button not clicked yet"
HorizontalOptions="Center" />
</VerticalStackLayout>
</ContentPage>
Learn more:
.NET MAUI fully supports the Model-View-ViewModel (MVVM) pattern with powerful data binding:
<Label Text="{Binding UserName}" />
<Entry Text="{Binding Email, Mode=TwoWay}" />
Learn more:
.NET MAUI includes powerful XAML features for cleaner, more efficient code:
<!-- Simplified property syntax -->
<Button Text="Click Me" Clicked="OnClicked" />
<!-- Markup extensions -->
<Label Text="{Binding Title}"
TextColor="{StaticResource PrimaryColor}" />
Learn more:
Shell provides a structured, performant navigation experience:
<Shell>
<TabBar>
<ShellContent Title="Home"
Icon="home.png"
ContentTemplate="{DataTemplate local:HomePage}" />
<ShellContent Title="Settings"
Icon="settings.png"
ContentTemplate="{DataTemplate local:SettingsPage}" />
</TabBar>
</Shell>
Learn more:
Display lists and collections with CollectionView:
<CollectionView ItemsSource="{Binding Items}">
<CollectionView.ItemTemplate>
<DataTemplate>
<Grid Padding="10">
<Label Text="{Binding Name}"
FontSize="18" />
</Grid>
</DataTemplate>
</CollectionView.ItemTemplate>
</CollectionView>
Learn more:
Build adaptive UIs that work across different screen sizes:
<Grid RowDefinitions="Auto,*"
ColumnDefinitions="*,*">
<Label Grid.ColumnSpan="2"
Text="Header" />
<BoxView Grid.Row="1"
Grid.Column="0"
Color="Blue" />
<BoxView Grid.Row="1"
Grid.Column="1"
Color="Green" />
</Grid>
Learn more:
We welcome your feedback and contributions!
.net-maui tagWe encourage contributions from the community! .NET MAUI is an open-source project.
.NET MAUI consists of several packages that work together:
| Package | Description |
|---|---|
| Microsoft.Maui.Controls | Core UI controls and XAML (this package) |
| Microsoft.Maui.Core | Platform abstractions and handlers |
| Microsoft.Maui.Essentials | Cross-platform APIs (merged into Core) |
| Microsoft.Maui.Graphics | Cross-platform graphics library |
| CommunityToolkit.Maui | Community-built controls and helpers |
.NET MAUI is licensed under the MIT License.
.NET MAUI is the evolution of Xamarin.Forms, building on years of mobile and cross-platform development experience. We thank the community for their continued support and contributions.