Need advice about which tool to choose?Ask the StackShare community!

ASP.NET Core

11.4K
2.6K
+ 1
1.6K
Next.js

6.9K
4.6K
+ 1
322
Add tool

ASP.NET Core vs Next.js: What are the differences?

Introduction

ASP.NET Core and Next.js are both popular frameworks used for building web applications. While ASP.NET Core is a framework developed by Microsoft, Next.js is a framework built on top of React.js. Although they share some similarities, there are several key differences between ASP.NET Core and Next.js that set them apart from each other.

  1. Language: One of the main differences between ASP.NET Core and Next.js is the programming language they use. ASP.NET Core is primarily developed using C#, while Next.js utilizes JavaScript. This means that developers familiar with C# will find it easier to work with ASP.NET Core, while those proficient in JavaScript will prefer Next.js.

  2. Server-side Rendering: Next.js is specifically designed for server-side rendering (SSR), which means that the web page is rendered on the server before being sent to the client. This allows for faster initial page loads and better SEO. On the other hand, ASP.NET Core supports both server-side rendering and client-side rendering (CSR), giving developers more flexibility in choosing the rendering approach based on their project requirements.

  3. Ecosystem and Community: ASP.NET Core has a long-standing history and a well-established ecosystem, supported by Microsoft. It has a large community with extensive documentation, libraries, and tools available. Next.js, being built on top of React.js, also benefits from a strong ecosystem and community support. However, it may not be as extensive as the ASP.NET Core ecosystem due to its relatively newer development.

  4. Platform Independence: ASP.NET Core is a cross-platform framework that runs on various operating systems, including Windows, macOS, and Linux. This allows developers to build applications that can be hosted on different platforms. Next.js, on the other hand, is primarily focused on building web applications and is not a cross-platform framework by itself. However, since it is built on top of React.js, React applications can be deployed on multiple platforms.

  5. Performance: When it comes to performance, ASP.NET Core is known for its speed and efficiency. It is highly optimized and leverages the full power of the underlying .NET framework. Next.js also performs well, especially in terms of initial page load and rendering. It utilizes server-side rendering and provides features like automatic code splitting and prefetching, resulting in fast and responsive web applications.

  6. Scalability: ASP.NET Core is designed to handle high-performance applications and can scale effectively to handle large workloads. It provides various scaling options, such as load balancing and clustering, to ensure application availability and performance. Next.js, being a framework built on top of React.js, can also scale well, especially when combined with serverless architectures and cloud platforms.

In summary, ASP.NET Core and Next.js have several key differences. ASP.NET Core uses C# as its primary programming language, supports both server-side rendering and client-side rendering, has a well-established ecosystem, runs on multiple platforms, and is known for its performance and scalability. Next.js, on the other hand, is built on top of React.js, focuses on server-side rendering, benefits from a strong JavaScript ecosystem, is primarily focused on web applications, and also provides good performance and scalability.

Advice on ASP.NET Core and Next.js
Taimoor Mirza
Associate Software Engineer at Intech Process Automation · | 5 upvotes · 725.9K views
Needs advice
on
ASP.NET CoreASP.NET Core
and
Spring BootSpring Boot

For context, I currently use JavaScript (React) and Python (Flask) in my daily routine.

I need your help in choosing either Spring Boot or ASP.NET Core. Both frameworks seem to have mature ecosystems. I would like to hear your thoughts on the following points:

  • Difficulty level of both frameworks
  • Level of community support
  • Career prospects i.e do Spring based jobs pay more or vice versa
  • which one will be helpful if I decide to transition towards a more specialized field like data engineering.

I am asking this because it is something that I am also exploring in parallel. I know that Python and #SQL play a huge role in big data.

See more
Replies (4)
Keegan Witt
Recommends
on
Spring BootSpring Boot

I'll preface this by saying I haven't ever done work on the Microsoft stack, so take this with a grain of salt.

Community support: Java tends to have a more active community (and much more diverse universe of new open source projects) than .Net (related to below).

Difficulty level: I'd say the Java/Spring stack is more difficult because Java developers tend to use more community projects and have to know which ones to choose in which circumstances (e.g. what logging framework to use? What database connection pooling library to use? What testing framework to use). That being said, most decisions you have to make have choices that are vastly more popular than others. My impression is that .NET guys use stuff from the standard library almost exclusively. If it's not provided there, it's a problem they never thought to solve or maybe write their own (usually the former).

Career prospects: I'll get hate for this probably, but Java/Spring has more jobs than .Net. .NET Core even more so because it's new. Most .NET jobs out there are going to be not Core, and not on anything other than Windows. LinkedIn search for jobs in United States shows 97,103 for Java and 36,448 for C#. That's not to say some individual city might not have more .NET than Java, but by and large Java is bigger. Also, .NET is not dying at the same pace as say Ruby on Rails (sorry Rails fans). I'd say it's ticking very slowly lower, maybe even holding steady. I wouldn't say you're screwed career-wise if you choose .NET. C# is also pretty similar to Java from what I've seen, and I know professionals that have transitioned to Java (though interestingly, I don't know any that did the reverse). Several companies have basically no .NET footprint, for example, Amazon, Google, Facebook, LinkedIn, Twitter all have Java, but basically no C#.

Specialized fields: Neither Spring or .Net are going to be a thing in a field like data science. That's exclusively Python (some R) for the most part. The only exception being that there is some Java in Hadoop, and Scala in Spark (which runs on the JVM). But I think those are generally more for data products being created, and not data science work. I'm also under the impression this is increasingly less the case than historically. Some other specialties might make Java useful, for example Android development.

In short, Java is the COBOL of the modern enterprise (which is both a good and bad thing). I recommend it to anyone over .NET, but not for technical reasons. It's for reasons related to the questions you asked. There are actually reasons I think CLR and C# are actually better from a technical perspective than Java (unsurprisingly, since they had the benefit of hindsight). But that's not what you were asking about...

See more
Recommends
on
Spring BootSpring Boot

Spring boot helps you creating microservices in hours, not days and there is a very active community around it with amazing integrations. Check one of the tutorials maybe. At least here in Germany, the job market will be better for Spring Boot as well, there are a lot more companies using Java then C#.

See more
Alexandru Muntean
Java Application Architect at IBM · | 4 upvotes · 535K views
Recommends
on
Spring BootSpring Boot

ASP.NET Core is pretty new while spring boot is very old but with a different name. Spring boot is just a pack of spring packages which make your life easier. I also believe that java community is way stronger than c# community... You can do your job in both frameworks and it's up to you what you choose after-all you're going to work on the project/lead it ... but whatever you choose.. after a few days of investment stick with your decision because in both frameworks you'll encounter challenges :)

See more
Klaus Nji
Staff Software Engineer at SailPoint Technologies · | 3 upvotes · 522.7K views

I’ll echo what others have said here with a few twists.

I have experience with both platforms including Micronaut, a relatively new kid on the block. It all depends on your near term goal. If it is to make money, sure Java jobs pay more generally because there is more hassles when dealing with the entire ecosystem. Like someone said earlier, you have to make a decision at almost every stage of the development cycle from the IDE, dependency resolution framework, logging, serialization, microservice framework etc. There is just too much choice which some may argue is an advantage while others may argue is a distraction and productivity killer. At the end of the day you can build solid systems with both frameworks.

Coming to ASP Core, yes I also agree that options are more streamlined. You’ll be using Visual Studio or Visual Studio code. For dependency management, you’ll be using Nuget. But I disagree with one of the comments above about the lack of choice. In some aspects .NET actually has more choice believe it or not for example choice of ORM. There is entity framework, nhibernate, dapper etc. For J2ee, hibernate reigns supreme although you have JPA. For dependency injection you have many IoC containers like unity, castle Windsor in .NET while you have Guice and maybe a Spring based implementation.

Also C# is technically a better language that Java. That’s not questionable as has also been stated above. Many things are done right obviously by avoiding some of the mistakes made in the underlying architecture surrounding the Java programming language. That’s why Microsoft created c# to begin with. The language is a lot cleaner and allows you to focus on learning core principles and nail down fundamental OO with emphasis on good design. I find too many distractions in the Java ecosystem which takes me away from understanding the core problem I am trying to solve.

So as you can this is not an easy decision and as someone has stated there’s work to do regardless of what technology choice you make.

If your sole purpose is to make a higher base salary, sure pick Spring Boot. If you want to quickly deliver something and iterate, pick ASP Core. I personally use c# for all private projects and proving concepts even though my employer is a Java shop. It allows me to stay focused on solving the problem and not constantly wrestle with issues such as Gradle dependency resolution glitches in IntelliJ.

Given that you can transfer skills from .NET to J2ee I recommend guys to pick up ASP get a couple of services to get a feel web development as you can still get jobs in Java even with that experience. Companies don’t care these days. In fact a lot of companies are going to Go so there’s that too.

Depends on your immediate term goal.

See more
Needs advice
on
ASP.NET CoreASP.NET Core
and
DjangoDjango

As a medium level .Net programmer trying to implementing a website, I decided to go through the Asp.Net Core. I found some tutorials on the web and started learning; however, I faced a problem. Even though I have been working with .Net and C# (mostly with unity game engine, which led to a quite amazing mobile game, published on a Persian app store) for two years or even more, by start learning Asp.Net Core, I found out that I do not know .Net as much as I expected. There were some things I should have learned before.

I searched for other frameworks, and Django was a popular one. Besides, I have planned to learn Python for machine learning. The website I want to make (with a small team) is nearly similar to Khan Academy. (We are going to use React for front-end)

So, What should I do? Continue working on .Net core with its amazing new features, or start getting into the Python and Django?

Your advice accompanied by reasons will be greatly appreciated!

See more
Replies (6)
Recommends
on
DjangoDjango

Having worked with many J2EE database applications in the past, I now turn to Django if I can and the project allows it as it is so quick to get up and running. It has a logical workflow and organized structure and it comes with a high level of security (if you import the appropriate backends). If you are wanting to incorporate python-based data processing (or cython), it is relatively easy to write a backend plugin. I have found it more stable with updates than other frameworks (particularly compared to the NPM world such as React which so often descends into dependency hell when a version of something is updated). One hassle worth mentioning is the database migrations support which can sometimes mess up during development but there are workarounds. With a React frontend, you would be using the Django REST Framework (https://www.django-rest-framework.org/) so you may find that you have to overwrite a lot of the methods here as the defaults are fairly basic CRUD operations which don't really support nested relationships very well. I don't have any experience with .Net so I can't give a comparison except of course, the obvious one, portability, as Python is platform-independent. PS, I would recommend Vue over React also for a well organized front-end.

See more
Recommends
on
DjangoDjango

I find myself in the opposite boat, I have made commercial websites with Django and now find myself learning ASP.NET. My recommendation comes with the following caveats... regardless of direction the learning will happen. Django is a very battery included framework, so the initial process will be painless, I found that documentation and support for more advanced use cases to be fairly easy to get support.

I personally found Django pretty nice to work with.

See more
Recommends
on
ASP.NET CoreASP.NET Core

You can get done what you want with just about any modern framework and language.

Django is fast and easy to learn but as your website grows you will need more and more community apps whose release cycles do not keep up with Django. Unless you are willing to work on the community apps, Django may not be for you.

Compare the active community sizes of Django apps to Ruby on Rails apps and you'll see very active communities with Ruby on Rails and small Django communities. Don't switch to Ruby on Rails though--it is a small, dying community of enthusiasts.

ASP.NET Core is a great backend framework, the community is large and you can always find answers; however, according to the StackOverflow developer survey, it is not desirable for the majority of programmers. I still use it though because my background evolved from C to C++ and then to C#. I also like the Microsoft world.

I've programmed a lot using Angular and some React but am switching to Vue.js which is much easier to learn and faster to code in. Be sure to use TypeScript with Vue.js. Just watch the video on the Vue home page to see how fast he can code using Vue.

But do you really want to code a website from scratch? If not, try WordPress Elementor. It may save you tons of time.

For mobile, use Google Flutter. In my 35 years of professional programming I've never seen anything more elegant, easy to learn, well documented and beautiful than Flutter. From one a single base you can target both Android and IOS and soon Web. You can also develop in Android Studio which means your screen real estate requirements are small so you don't need two monitors.

See more
Recommends
on
ASP.NET CoreASP.NET Core

Go with the ASP.NET Core. It is a very mature technology now and there are tons of documentation, tutorials and support you can find online. Also ASP.NET Core Web API plays quite well with the React. It is easy to implement the entire back-end in .NET Core (APIs, authentication, database access layer...) and if you need any third party package, I'm pretty sure you will find and implement in a form of a NuGet package. Who knows, maybe one day you'll need to create a mobile app and with a fully functional Web API, it would be more-less easy task to build a mobile app on top of it.

See more
Recommends
on
FirebaseFirebase

I recommend you use a framework such as Firebase instead of implementing your own backend server for the website.

I found that Firebase enables me to build websites more quickly since it takes care of the backend for me so most of my development time is building the front-end (using React in your case).

See more
Ilya Lebedev
Recommends
on
DjangoDjango

If you're going to learn Python anyway, Django project will boost your learning process. Since you're going to use React , you only neet to create REST API. Basic API can be created with Django rather easy.

See more
Needs advice
on
ASP.NET CoreASP.NET Core
and
DjangoDjango

I have a mission to make a web application for my organization (engineering consultant). With the following bullet points that the new web app has to cover, what is the right tool?

  1. It should be able to display employee data and project data. For example, when searching the name of Mr. Peter Parker, I should be able to click on the name to see his personal profile and also a list of construction projects he is or was a part of. Also, if I click on a project name, say Project ABC building, it should show me the detail of this project (who is the client, who works on this project, where, start-finish dates, etc.)

  2. It should be able to sync with the database from Microsoft Access.

(optional) 3. The user of this web app should be able to propose a rotation of role (Ex. Boss might want Mr. Peter Paker to work in another project next month, he can just drag Peter into XYZ Building.)

See more
Replies (4)
Mohammad Hossein Amri
Chief Technology Officer at Planally · | 8 upvotes · 256.3K views
Recommends
on
ASP.NET CoreASP.NET Core

you can achieve what you want with both. but for me, the obvious choice is Aspnet core. the main reason is being the easiness of writing code in a multi-threading manner & ORM. the Django ORM is ugly as hell that I don't even want to look into its code. I did a couple of projects with Django and I wish I never did it. the amount of nuances was so much that after we delivered the projects I rejected any new Django project. I know people still using that and getting projects done but it's not a clever choice when there are easier choices out there.

moreover, after the latest upgrade, the Aspnet core 3 is the fastest and best of framework in 2020.

See more
George Krachtopoulos
Recommends
on
DjangoDjango

I always use Django on my projects. It is really easy and friendly fro the developer. It also comes with an inbuilt admin panel where you can manage all your models (tables), Django has a great authentication and authorization system, and it provides a great and powerful URL dispatcher, suitable for your needs. Furthermore, you can use a called django-pyodbc that is coded specifically for Microsoft SQL Server, and the SQL dialects for SQL Server ("T-SQL") and Access ("Access SQL"). However, I would not recommend using an Access DataBase with any web application's backend. Of course, it depends if you explicitly have Microsoft as your main tech stack.

Hope I helped you, and good luck with your project!

See more
Paresh Kadam
Software Developer at Tavisca · | 4 upvotes · 255.7K views
Recommends
on
ASP.NET CoreASP.NET Core

Would recommend Asp.net core with angular, It would integrate fine. I have experienced Django its good for fast, short span projects. But when it comes to speed, maintainability Asp .net is a winner. Though you can use angular/react in both frameworks. Your application consists of crud operations so you can have a choice based upon availability of resource, maintenance and time

See more
Recommends
on
ASP.NET CoreASP.NET Core

Short answer, ASP.NET because of #2. I think the Microsoft stack, now and in the future will be easier to sync with Microsoft Access. I haven't done extensive research but usually Microsoft office apps work well with the MSFT stack. BUT I personally prefer Django.

See more
Decisions about ASP.NET Core and Next.js
Lucas Litton
Founder & CEO at Macombey · | 13 upvotes · 541K views

Next.js is probably the most enjoyable React framework our team could have picked. The development is an extremely smooth process, the file structure is beautiful and organized, and the speed is no joke. Our work with Next.js comes out much faster than if it was built on pure React or frameworks alike. We were previously developing all of our projects in Meteor before making the switch. We left Meteor due to the slow compiler and website speed. We deploy all of our Next.js projects on Vercel.

See more

Hey guys,

My backend set up is Prisma / GraphQL-Yoga at the moment, and I love it. It's so intuitive to learn and is really neat on the frontend too, however, there were a few gotchas when I was learning! Especially around understanding how it all pieces together (the stack). There isn't a great deal of information out there on exactly how to put into production my set up, which is a backend set up on a Digital Ocean droplet with Prisma/GraphQL Yoga in a Docker Container using Next & Apollo Client on the frontend somewhere else. It's such a niche subject, so I bet only a few hundred people have got a website with this stack in production. Anyway, I wrote a blog post to help those who might need help understanding it. Here it is, hope it helps!

See more
Alexander Krylkov
Sofrware Architect at Air Astana · | 2 upvotes · 208.8K views

Comparing to ASP.NET Core MVC or ASP.NET Core Web API Simplify.Web allows you to easily build your web-site or REST API without any additional/complicated setup, covering cases like localization by default. It's projects structure very lightweight, just a minimum amount of what you need to setup ASP.NET Core request pipeline.

It is build on top of Simplify.DI IOC container abstraction, no dependency on Microsoft.Extensions.DependencyInjection and it's syntax. You can easily switch between DryIoc, SimpleInjector, CastleWindsor etc.

Any internal module of Simplify.Web can be easily replaced on extended by your custom module, covering your custom cases.

For HTML pages generation Simplify.Templates can be used allowing you to use just regular plain HTML without additional setup.

Can be easily integrated with Simplify.WindowsServices converting your web application not just to web-application, but a standalone windows service which can also do some background jobs via Simplify.WindowsServices.

And it is open source, of course :)

See more

There has been a lot of buzz around having PostgreSQL for ASP.NET Core 3.1 web apps. But Configuring Identity Server 4 with PostgreSQL is a real challenge. I've made a simple video to configure the ASP.NET Core 3.1 based Web application that uses AngualrJS as front end with Single Page App capabilities with Identity Server 4 talking to the PostgreSQL database. Check out this Video tutorial on how to do that in detail http://bit.ly/2EkotL5 You can access the entire code here on github http://bit.ly/35okpFj

See more
Get Advice from developers at your company using StackShare Enterprise. Sign up for StackShare Enterprise.
Learn More
Pros of ASP.NET Core
Pros of Next.js
  • 139
    C#
  • 116
    Performance
  • 93
    Open source
  • 88
    NuGet
  • 83
    Easy to learn and use
  • 81
    Productive
  • 77
    Visual Studio
  • 73
    Fast
  • 70
    Fast Performance With Microservices
  • 66
    Easily Expose API
  • 63
    Cross Platform
  • 61
    Scalable
  • 60
    Rapid Development
  • 55
    Web Apps
  • 46
    Visual Studio Code
  • 44
    Easy to learn
  • 39
    Azure Integration
  • 38
    MVC
  • 34
    Professionally Developed Packages
  • 32
    Great MVC and templating engine with Razor
  • 31
    Signalr
  • 31
    Razor Pages
  • 30
    Dependency Injection
  • 26
    JetBrains Rider
  • 25
    Easy to start
  • 24
    Tooling
  • 20
    One stop shop
  • 20
    MVVM
  • 16
    Fantastic and caring community
  • 11
    Add a pro
  • 10
    High Performance
  • 9
    Linux Support
  • 4
    Native AOT
  • 3
    Integration test easy & reliable
  • 3
    Free
  • 3
    WASI/WAGI
  • 3
    Easy tooling to deploy on container
  • 49
    Automatic server rendering and code splitting
  • 43
    Built with React
  • 33
    Easy setup
  • 26
    TypeScript
  • 24
    Universal JavaScript
  • 22
    Zero setup
  • 21
    Static site generator
  • 12
    Simple deployment
  • 12
    Just JavaScript
  • 12
    Incremental static regeneration
  • 10
    Filesystem as an API
  • 10
    Frictionless development
  • 9
    Everything is a function
  • 9
    Well Documented
  • 8
    Has many examples and integrations
  • 8
    Testing
  • 7
    Isomorphic React applications
  • 4
    File based routing + hooks built in
  • 2
    Deployment
  • 1
    SEO

Sign up to add or upvote prosMake informed product decisions

Cons of ASP.NET Core
Cons of Next.js
  • 5
    Great Doc
  • 3
    Fast
  • 2
    Professionally written Nuget Packages, vs IMPORT junk
  • 2
    Clean
  • 1
    Long polling is difficult to implement
  • 9
    Structure is weak compared to Angular(2+)

Sign up to add or upvote consMake informed product decisions

- No public GitHub repository available -

What is ASP.NET Core?

A free and open-source web framework, and higher performance than ASP.NET, developed by Microsoft and the community. It is a modular framework that runs on both the full .NET Framework, on Windows, and the cross-platform .NET Core.

What is Next.js?

Next.js is a minimalistic framework for server-rendered React applications.

Need advice about which tool to choose?Ask the StackShare community!

What companies use ASP.NET Core?
What companies use Next.js?
See which teams inside your own company are using ASP.NET Core or Next.js.
Sign up for StackShare EnterpriseLearn More

Sign up to get full access to all the companiesMake informed product decisions

What tools integrate with ASP.NET Core?
What tools integrate with Next.js?

Sign up to get full access to all the tool integrationsMake informed product decisions

Blog Posts

What are some alternatives to ASP.NET Core and Next.js?
ASP.NET
.NET is a developer platform made up of tools, programming languages, and libraries for building many different types of applications.
Django
Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.
Spring Boot
Spring Boot makes it easy to create stand-alone, production-grade Spring based Applications that you can "just run". We take an opinionated view of the Spring platform and third-party libraries so you can get started with minimum fuss. Most Spring Boot applications need very little Spring configuration.
React
Lots of people use React as the V in MVC. Since React makes no assumptions about the rest of your technology stack, it's easy to try it out on a small feature in an existing project.
Blazor
Blazor is a .NET web framework that runs in any browser. You author Blazor apps using C#/Razor and HTML.
See all alternatives