In this article, I will explain the difference between the .NET Core Vs .NET Framework and why use .Net Core. Keep reading on Interview Questions on ASP.NET Core.
What is .Net core vs .Net Framework
Let us discuss some of the major differences between .Net Core vs .Net Framework:
.Net Framework is a software development framework designed and maintained by Microsoft. It is Windows-based and primarily runs on Windows devices. It is used for the development of standalone desktop as well as web applications. The framework provides all the basic requirements for the development of applications – UI, DB connectivity, Services, APIs, etc.
.Net Core is an open-source development platform designed and maintained by Microsoft and the .Net community. .Net Core has been designed keeping in mind various needs and purposes, focusing on Web Development, Windows Phone Development, and Windows Store Apps Development.
.Net Core vs .Net Framework Comparison Table
|.Net Framework||.Net Core|
|Platform or Framework||.Net Framework is a full-fledged development framework. The framework provides all the basic requirements for the development of applications – UI, DB connectivity, Services, APIs, etc.||.Net Core is a platform on top of which there are frameworks such as ASP .Net Core and Universal Windows Platform that leverage and extend the features of .Net Core.|
|Open Source||.Net Framework is not open-source. It is more of a community-developed software project.||.Net Core is open-source.|
|Cross-Platform||Although, .Net Framework was designed to develop software and applications for all the operating systems, yet it ended up favoring Windows. Thus, .Net Framework is majorly used to develop Windows-based applications.||Net Core follows the principle of build-once-run-anywhere. Thus, it is cross-platform. It supports Windows, macOS and Linux platforms. You can build your application on any platform and run on another.|
|Types of Applications||.Net Framework is used to build both Desktop as well as Web applications.|
Windows Forms and WPF applications are very well supported.
|Net Core focuses more on Web, Windows Mobile, and Windows Store applications. Currently, it does not support Desktop application development.|
|Packaging and Shipping||.Net Framework is packaged as a whole. All the libraries are bundled together and shipped together.|
Even if you do not require any library for your application, it still comes as a part of the package.
|.Net Core is delivered as a set of NuGet packages. It has been factored, modularized and shipped as several NuGet packages.|
Although the common runtime libraries are still a part of the bundle, the developer has the freedom to selectively include other libraries as per need. This makes .Net Core very lightweight. No extra baggage.
|Support for Microservices||.Net Framework does not support the creation and deployment of microservices in different languages.||.Net Core has support for microservices. .Net Core allows a mix of technologies that can be minimalized for each microservice.|
|Support for WCF/REST Services||.Net Framework is an excellent choice when WCF services are involved. It also supports REST services.||.Net Core has no support for WCF services. You would always need to create a REST API.|
|CLI Tools||Net Framework is too heavy for Command Line Interface. Some developers prefer working on CLI rather than an IDE.||.Net Core supports a very lightweight CLI for all platforms. There is always an option to switch to an IDE as well.|
Why use .Net Core
- Can be Developed and Deployed on Various Environments (Windows, Linux, macOS).
- Smaller Application Size.
- Cost-saving by hosting on Linux (cross-platform).
- Better Performance.
- Container ready.
- Azure ready.
- Completely open-source on Github.
- Runs on raspberry pi.
- Built-in Dependency injection.
- Built-in Logging.
- Changing the app config application won’t restart.
- Ready for MicroService Architecture.
- Grpc Support.
- Developing Desktop Application (Windows Only).
- C# 8.0.
- Good Support for Client-Side Application React, Angular, Vue JS.
I hope you liked this article on the what is .net core vs .net framework. I would like to have feedback from my blog readers. Your valuable feedback, question, or comments about this article are always welcome.