Overview of XAML

Applies to: yesVisual Studio noVisual Studio for Mac

Extensible Application Markup Language (XAML) is a declarative language that's based on XML. XAML is used extensively in the following types of applications to build user interfaces:

The following XAML code defines a simple button control.

<Button Click="ButtonClick">Show updates</Button>

XAML is also used to define workflows in Windows WorkFlow Foundation (WF) apps.

XAML code editor

The XAML code editor in the Visual Studio IDE includes all the tools you need to create WPF and UWP apps for the Windows platform, and for Xamarin.Forms. And although the IDE (integrated development environment) in Visual Studio has many features that you can use to develop apps for other platforms, it also has some features that are unique to XAML, too.

XAML Designer

Visual Studio and Blend for Visual Studio provide a XAML Designer that helps you build user interfaces (UI) for WPF, UWP, and Xamarin.Forms apps. You can drag controls from the Toolbox or Assets window and set properties in the Properties window. When you do so, Visual Studio and Blend for Visual Studio create the corresponding XAML code. If you prefer to edit the XAML code directly, you can do that too.

What's new

For the latest information, refer the following resources:

See also