The .NET ecosystem is a grid of frameworks, libraries and specifications.
At the bottom we have the fundamentals – the platform specific compilers & runtimes, C# and the fundamental basics needed to run a C# application on each platform.
On top of the foundation lies the .NET Standard
library specification. It holds all of the code API definitions that is are not platform or environment specific library like LINQ and collection types and lots of components in the
System namespace. The top layer implements these specifications to be compatible to the .NET Standard API specification. So if a version of .NET Core and one of Xamarin both implement the .NET Standard 2.0 APIs they can use any library or other logic that targets .NET Standard 2.0.
As .NET Standard is open source you can explore it yourself at https://github.com/dotnet/standard/.
The top layer of the .NET ecosystem has
3 columns 4 columns.
The .NET Framework is the column for windows-only development. It is used for the classical desktop Windows Forms applications, the more modern WPF (Windows Presentation Foundation) desktop applications and the classical ASP.NET.
All three need windows desktop or server to run (x64 or x86 only).
.NET Core is the multi-platform column. It is the basis for ASP.NET Core as the web hosting framework
, UWP for desktop and (Windows) mobile & tablet and can be used for command line programs.
.NET Core runs on Windows, Linux and macOS on x64, x86 & ARM 32&64 Bit. So no matter if you want to run your app on your Windows or Mac development machine, on a hosting service like Azure, Linode or AWS or on a Raspberry Pi, you have all the options covered you could ever need.
Only downside right now: There are no official offline GUI frameworks for core, yet. But I expect to see more options and frameworks in this column on the horizon. Probably official and unofficial, third party, ones like Avalonia.
UWP is relatively new to the .NET Standard 2 stack. (See here and here), but already supports .NET Standard 1 since UWP 10.0.
The UWP (Universal Windows Platform) targets all the different windows platforms that can run the Windows Runtime and have the Microsoft Store; also the non-desktop/server ones. This means Windows 8 & 10, Windows RT/Surface Hub, Windows 8/10 for tablets and mobile phones, Xbox, IoT devices and even HoloLens.
Generally UWP runs anything that shows in the “Modern UI” (formerly known as “Metro UI”).
Xamarin is the last top column. This is the column you have to choose for iOS and Android development as well as macOS (formerly known as OS X) desktop applications.
We will see what Mono-based GUI-frameworks will do to cannibalize this by making those platforms available for .NET Core.
The beauty of it
What I really love in this structure is, that if you keep an eye on the separation of concerns and single responsibility principle in your code base, the actual code written in .NET Core, Xamarin, UWP or WPF should be fairly thin.
In return this means if you do your job well, you can use a big share of your business logic in multiple clients or front ends without laying a hand on it. A brilliant side-effect of this is, that bringing your application to a new platform can be very quick and continuing support for multiple platforms can be achieved very efficiently.
The sources on this topic are mostly dated, but a good extension.
Thanks to the keen and attentive reddit community in /r/dotent and /r/csharp I learned, that my sources were dated and no longer gave the right picture of the current situation. Also the old diagrams I used as template for the diagram in this post were not really accurate to the final structure of the ecosystem. UWP does not run on .NET Core, but uses parts of .NET Core for debugging in Visual Studio and supports .NET Standard 2.0 if targeting the Windows 10 Fall Creators Update.
Last but not least I stated .NET Standard to be a library. That was not accurate. It is a specification of APIs that need to be implemented by frameworks targeting a specific .NET Standard version.
I updated the post to reflect those corrections.