WHY ASP.NETASP.NET extends the .NET platform with tools and libraries specifically for building web apps.
These are some things that ASP.NET adds to the .NET platform:
Base framework for processing web requests
Web-page templating syntax, known as Razor, for building dynamic web pages using C#
Libraries for common web patterns, such as Model View Controller (MVC)
Authentication system that includes libraries, a database, and template pages for handling logins, including multi-factor authentication and external authentication with Google, Twitter, and more.
Editor extensions to provide syntax highlighting, code completion, and other functionality specifically for developing web pages
Razor provides a syntax for creating dynamic web pages using HTML and C#. Your C# code is evaluated on the server and the resulting HTML content is sent to the user.