The Universal Windows Platform is a common software platform for all devices running Windows 10, including Desktop. This tag should be used for questions regarding developing UWP applications on any of the supported device families. Other tags such as the languages being used (C#, C++, etc.) and the style of API (Win32, WinRT, etc.) can be added. Packaged Win32 Applications should use the Desktop-Bridge tag (possibly in addition to UWP).
Universal Windows Platform
Windows 10 introduced the Universal Windows Platform which was an evolution of the "modern" platform first introduced with Windows 8. UWP replaces the disparate legacy platforms and unifies all Windows devices (Desktop, Xbox, IoT, Surface Hub, HoloLens, etc.). UWP is the focus of all future Windows platform innovation at Microsoft - including on Desktop Windows - with many of the original differences between "UWP apps" and "Desktop Win32 apps" having been removed. UWP consists of Win32, COM, WinRT, and .NET APIs.
UWP introduced or refined several new technologies, many of which are now available to Win32 apps:
- MSIX (nee AppX) packaging.
- Declarative extensibility and integration points.
- AppContainer-based security and privacy.
- MRT resource packaging and resolution.
- XAML-based UI, including modern input (touch, pen, and game controller).
- WinRT platform APIs.
- The Microsoft Store
MSIX enables the clean install, servicing, and uninstall of applications, including packaged Win32 applications. It enables apps to integrate with the Windows shell and cooperate with other apps via a declarative extension mechanism.
AppContainers run apps with a minimal set of permissions by default, ensuring they are isolated from each other and the system. AppContainers use an explicit permissions-based security model (known as "capabilities") to request additional access to resources like the network, the user's location, or a camera. Packaged Win32 apps do not typically run inside an AppContainer.
MRT is a unified resource management technology, allowing apps to specify resources across a diverse set of axis (language, scale-factor, accessibility, home region, etc.) with the most-applicable candidate being loaded automatically at runtime. MRT is available to Win32 applications.
XAML, the UI framework for UWP, uses a declarative XML dialect to define UI layout. It will be familiar to anyone who has used WPF or Silverlight, but XAML has been updated to better integrate with DirectX rendering and use modern inputs such as touch, pen, and game controller. It is also no longer limited to .NET languages (it is usable from C++) and it can be used from Win32 applications.
The runtime platform consists of a set of Windows Runtime (WinRT) APIs, a growing subset of COM & Win32 APIs, and a cross-platform set of .NET APIs. Most UWP APIs are available on all Windows devices, and most UWP APIs are available to Win32 or Packaged Win32 apps as well. Using the Desktop Extension SDK, Packaged Win32 apps can access virtually any existing Windows API or feature, but only work on Desktop Windows devices. Even if an application uses device-specific functionality, it can still run on other UWP devices if it avoids calling the specialized APIs when they are not available.
UWP apps (including Packaged Win32 apps) can be distributed via the Microsoft Store, but they can also be side-loaded onto most devices with traditional deployment mechanisms (enterprise deployment, web download, MSI-based installers, etc.). By default, all applications created with Visual Studio are able to run on all Windows 10 devices, but developers can restrict distribution in the Microsoft Store to one or more specific devices if they have a technical or business need to do so.